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

No clear option/documentation for local/staging/production config management #9

Open
sunweiyang opened this issue Nov 1, 2019 · 1 comment

Comments

@sunweiyang
Copy link

Committing firebase.json to a repo should not be the way to deploy a Django server (I have a Heroku Django app, and committing that file is the only way I can use drf-firebase-auth as it exists today). There should be a way to set the contents of firebase.json as an environment variable.

@sherzberg
Copy link

@sunweiyang I also didn't want to commit the file or put the file on the filesystem so I dug a little bit and found out that the way drf-firebase-auth sets up the firebase_admin credentials is pretty generic and you can just set the value of FIREBASE_SERVICE_ACCOUNT_KEY to a dict: https://github.com/firebase/firebase-admin-python/blob/master/firebase_admin/credentials.py#L84

So in my code I'm just reading in the json from a secret manager (I happen to be using AWS Secrets Manager), but if you have access to some cloud storage or secret manager, you could just read in the json yourself and parse it to a dict.

Maybe this could be documented?

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

No branches or pull requests

2 participants