Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hosting:channel:deploy seems to ignore "--no-authorized-domains" #3740

Closed
johncarter-phntm opened this issue Sep 7, 2021 · 2 comments · Fixed by #3741
Closed

hosting:channel:deploy seems to ignore "--no-authorized-domains" #3740

johncarter-phntm opened this issue Sep 7, 2021 · 2 comments · Fixed by #3741
Assignees

Comments

@johncarter-phntm
Copy link

My firebase project has Firebase hosting enabled, but isn't using Firebase auth.

When I do a hosting:channel:deploy I get a warning about Firebase auth channel domain sync, even if I use the --no-authorized-domains option that's listed in --help: "do not sync channel domains with Firebase Auth".

I would have expected that option to suppress this warning?

⚠  hosting:channel: Unable to add channel domain to Firebase Auth. Visit the Firebase Console at https://console.firebase.google.com/project/myproject/authentication/providers


⚠  hosting:channel: Unable to sync Firebase Auth state.

[REQUIRED] Environment info

firebase-tools:

9.17.0

Platform:

Ubuntu 20.04.3

[REQUIRED] Test case

firebase hosting:channel:deploy example --expires=1h --no-authorized-domains

[REQUIRED] Steps to reproduce

Set up a Firebase project with hosting enabled but without Firebase any auth providers enabled.

[REQUIRED] Expected behavior

Deploy to complete without warning.

[REQUIRED] Actual behavior

<...snip...>
✔  Deploy complete! 

Project Console: https://console.firebase.google.com/project/myproject/overview
Hosting URL: https://myproject.web.app

[2021-09-07T23:07:42.778Z] > refreshing access token with scopes: []
[2021-09-07T23:07:42.778Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token  
 <request body omitted>
[2021-09-07T23:07:43.264Z] <<< HTTP RESPONSE 200 {"cache-control":"no-cache, no-store, max-age=0, must-revalidate","pragma":"no-cache","date":"Tue, 07 Sep 2021 23:07:43 GMT","expires":"Mon, 01 Jan 1990 00:00:00 GMT","content-type":"application/json; charset=utf-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","server":"scaffolding on HTTPServer2","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3=\":443\"; ma=2592000,h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2021-09-07T23:07:43.275Z] >>> [apiv2][query] GET https://identitytoolkit.googleapis.com/admin/v2/projects/myproject/config [none]
[2021-09-07T23:07:44.068Z] <<< [apiv2][status] GET https://identitytoolkit.googleapis.com/admin/v2/projects/myproject/config 404
[2021-09-07T23:07:44.068Z] <<< [apiv2][body] GET https://identitytoolkit.googleapis.com/admin/v2/projects/myproject/config {"error":{"code":404,"message":"CONFIGURATION_NOT_FOUND","status":"NOT_FOUND"}}
⚠  hosting:channel: Unable to add channel domain to Firebase Auth. Visit the Firebase Console at https://console.firebase.google.com/project/myproject/authentication/providers

 
[2021-09-07T23:07:44.074Z] [hosting] unable to add auth domain HTTP Error: 404, CONFIGURATION_NOT_FOUND {"name":"FirebaseError","children":[],"context":{"body":{"error":{"code":404,"message":"CONFIGURATION_NOT_FOUND","status":"NOT_FOUND"}},"response":{"statusCode":404}},"exit":1,"message":"HTTP Error: 404, CONFIGURATION_NOT_FOUND","status":404}
[2021-09-07T23:07:44.077Z] >>> [apiv2][query] GET https://firebasehosting.googleapis.com/v1beta1/projects/myproject/sites/myproject/channels pageToken=&pageSize=10
[2021-09-07T23:07:45.597Z] <<< [apiv2][status] GET https://firebasehosting.googleapis.com/v1beta1/projects/myproject/sites/myproject/channels 200
[2021-09-07T23:07:45.598Z] <<< [apiv2][body] GET https://firebasehosting.googleapis.com/v1beta1/projects/myproject/sites/myproject/channels {"channels": <<<snip>>>
[2021-09-07T23:07:45.600Z] >>> [apiv2][query] GET https://identitytoolkit.googleapis.com/admin/v2/projects/myproject/config [none]
[2021-09-07T23:07:46.148Z] <<< [apiv2][status] GET https://identitytoolkit.googleapis.com/admin/v2/projects/myproject/config 404
[2021-09-07T23:07:46.148Z] <<< [apiv2][body] GET https://identitytoolkit.googleapis.com/admin/v2/projects/myproject/config {"error":{"code":404,"message":"CONFIGURATION_NOT_FOUND","status":"NOT_FOUND"}}
⚠  hosting:channel: Unable to sync Firebase Auth state. 
[2021-09-07T23:07:46.149Z] [hosting] unable to sync auth domain HTTP Error: 404, CONFIGURATION_NOT_FOUND {"name":"FirebaseError","children":[],"context":{"body":{"error":{"code":404,"message":"CONFIGURATION_NOT_FOUND","status":"NOT_FOUND"}},"response":{"statusCode":404}},"exit":1,"message":"HTTP Error: 404, CONFIGURATION_NOT_FOUND","status":404}
✔  hosting:channel: Channel URL (myproject): https://myproject--example-rdwnl9bn.web.app [expires 2021-09-08 12:07:34] [version e58c8dbff7337910] 

@bkendall
Copy link
Contributor

bkendall commented Sep 8, 2021

Thanks for escalating. I fixed this and it'll be out in the next release!

@bkendall bkendall self-assigned this Sep 8, 2021
@johncarter-phntm
Copy link
Author

Awesome, thanks for the quick turnaround!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants