repository secrets

#199
by mfood303 - opened

can someone please explain to me how the DOTENV_LOCAL secret works?

is it restricted to:

MONGODB_URL=<the URL to your mongoDB instance>
HF_ACCESS_TOKEN=<your access token>

or can anything from the .env file go into it?

also if i duplicate this space, can i eliminate the DOTENV_LOCAL secret, create separate secrets for MONGODB_URL and HF_ACCESS_TOKEN, and then code them into .env.local?

lastly, should the HF_ACCESS_TOKEN have read or write functionality?

Hugging Chat org

Hi! Thanks for your question.

The DOTENV_LOCAL has higher priority than the .env so you can use all the variables you want within your DOTENV_LOCAL and they will override .env.

I think environment variables have the highest priority so you could indeed specify the environment variables individually like MONGODB_URL as secrets instead of putting them all in DOTENV_LOCAL and it should work, although I haven't tried it. In that case you don't even need a .env.local file as the variables will get picked up from your environment.

And I believe the token only needs read access. Let me know if that helps!

Sign up or log in to comment