angular / angularfire

Angular + Firebase = ❤️
https://firebaseopensource.com/projects/angular/angularfire2
MIT License
7.67k stars 2.19k forks source link

Angular9 SSR Functions Region #2558

Closed willroxby closed 3 years ago

willroxby commented 4 years ago

Version info

Angular: 9.1.9

Firebase: 7.14.2

AngularFire: 6.0.2

Other (e.g. Ionic/Cordova, Node, browser, operating system):

Expected behavior

I want to change my SSR Function to deploy to region - europe-west1.

Actual behavior

When I run ng deploy the index.js is overwritten, setting the region back to us-central1.

Is there a way to change the default index.js file to update the region the function gets deployed to.

Current index.js - Image

saurabh1234 commented 4 years ago

I am also interested.

jamesdaniels commented 3 years ago

I wouldn't advise this at this time as Firebase Hosting requires the function be in us-central-1, https://firebase.google.com/docs/hosting/functions

mkayswork commented 3 years ago

Unfortunately, this doesn't solve the problem. Assuming I want to host a ssr angular application while my customer all sit in Europe, my score via lighthouse gets worse from this config. Is there any way to configure the region properly? As soon as I set the region like mentioned in the docs, my command ng deploy fails.