Default redis variable names

Issues information

  • OS: Windows 11
  • databases: redis
  • Programming language and version: not applicable
  • Link to your project on Github/Gitlab: not applicable

Your issue

database docs aren’t clear

Describe here your issue

the docs say that the var name for a sql db in qovery is QOVERY_DATABASE_MY_DB_CONNECTION_URI.

what is it called in the case of redis, i mean, the var names of the endpoint and password.?

(just didnt get what then endpoint (url) and password is called, as there are a lot of vars in secrets named with redis/database and i cant see its value)

the docs are not updated yet for v2.

could i get the var names for REDIS endpoint and password, so that i could proceed… there are a lot of vars in secrets named with redis and database and i cant see its value, so its confusing…
thanks!

@Erebe maybe you can help him with this.

any updates on this…?

@Erebe does the env variable QOVERY_{DB_TYPE}_{DB_ID}_DATABASE_URL disappeared for some reason? It was added last week. I no longer see it

On your application page in the dashboard, there is a tab for “Environment Variables”, you should have your DB connection keys under “Secret variables”, you can also create aliases for them from a kebab dropdown if you want them a little more generic.

1 Like

I saw them, but the values in them were force hidden with no option to view it, which caused confusion.

I manually printed out each value and sorted it out. Thanks for all the replies!

I am glad you got that sorted out, but ideally you shouldn’t hardcode these values, but use the provided environment variables instead. Not sure what stack your project uses but you should be able to access environment variables in your app, as an example in Node it’s done via process.env.NAME_OF_ENV_VARIABLE.

The benefit of environment variables is in fact that they are hidden and dynamic, so you are not committing any credentials or secrets to your repo but also if something changes on the server, you don’t have to change that in your code.

I didn’t mean that btw.
The vars are named as QOVERY_DBType_random hash_type, which caused some confusion as to what values each one contained.
I checked the values of each and figured out waht is what, and it done!
Thanks :ok_hand:

1 Like