I am trying to move the tiny node-express app I made into Firebase functions.
The files have dotenv
variables. Earlier I thought If I just deployed and put the dotenv in dependency, It would work but that didn't happen so...
So, I went to the environment configuration article of Firebase to understand how I can set .env
Which states to set things by doing something like this
firebase functions:config:set someservice.key="THE API KEY" someservice.id="THE CLIENT ID"
But I have so many environment configurations and doing that some what seems to be a cumbersome task.
So let's say this is an environment file
# App port Address
PORT = 8080
# Google Secret
GOOGLE_CALLBACK_URL = http://localhost:8080/auth/google/callback
GOOGLE_CLIENT_ID = 40xxxx8-xxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com
GOOGLE_CLIENT_SECRET = lxxxxxxxxxxxxO
# Client Address
CLIENT_ADDRESS = http://localhost:3000/
# Meetup Secret
MEETUP_CALLBACK_URL = http://localhost:8080/auth/meetup/callback
MEETUP_CLIENT_ID = exxxxxxxxxxxxxxxxxxxt
MEETUP_CLIENT_SECRET = sxxxxxxxxxxxxxxxxt
#EventBrite Secret
EVENTBRITE_CALLBACK_URL = http://localhost:8080/auth/eventbrite/callback
EVENTBRITE_CLIENT_ID = UxxxxxxxxxxxxxN
EVENTBRITE_CLIENT_SECRET = Nxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx4
How Can I best set up so that when I do firebase firebase serve --only functions,hosting it doesn't throw any errors such as
OAuth2Strategy requires a clientID option