Auth0-deploy -Storing client secret in a separate config file

Hi,
I’m trying to deploy my settings using auth0-deploy. I have multiple environments / tenants, so I have created a config.stage.json as well as a config.production.json file to store the settings for the different environments.
My challenge is that these files contain the “AUTH0_CLIENT_SECRET” which I don’t want to check in to source control. Can I create another file to hold this value (config.production.json.secret) and have it merged with the other file? I’m aware that I can use environment variables on my windows computer, but the client secret is different from stage and prod, so storing it there wont work.
Any other way I can achieve this?

1 Like

I am looking for an answer to this too; the docs mention environment variable mappings which seem like they are meant to help in situations like this but either they don’t work for the ID and secret or I’m just setting them wrong.

I know this is a bit late, but in case anyone else runs across this or you’re still struggling with it, auth0-deploy can just read that from an environment variable, so you can just leave AUTH0_CLIENT_SECRET out of your config.json entirely, set the value with something like export AUTH0_CLIENT_SECRET=supersecretstring, and then call a0deploy.

2 Likes

Thanks a lot for sharing it with the rest of community @michelle.avery!

Exactly what I needed! You just saved me several hours. Thanks!
myprepaidcenter login

1 Like

Glad you were able to sort out your struggles with that reply Scott!

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.