I am deploying an app using DigitalOcean Apps (Which was amazingly straightforward by the way!) However I can’t work out how to handle keys for my Firebase Admin connection. The docs specify that a JSON file should hold all the params: https://firebase.google.com/docs/admin/setup
The safest way to handle these creds securely would seem to be to use a build command to pull the JSON file from a store. (I want to use an environment variable to pull the right JSON file according to which environment I am deploying).
I was hoping to use a DO Space, but there appears to be no easy way to pull from it using a Build command as it needs to use the S3 API/ SDK which is not available to a build command for an App. Does anyone know how I might go about pulling this at build time?
Only other thing I can think is to run a shell script that builds my JSON from environment variables, but that seems like a sub-optimal solution!
Any suggestions welcome as I am quite new to this!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Click below to sign up and get $100 of credit to try our products over 60 days!