Open utterances-bot opened 2 years ago
Amazing doc !
I have a question, when we link an add-on to an application, its main informations are injected in the application with generic labels (f.e. POSTGRESQL_ADDON_HOST
for a PostgreSQL database).
Is it possible (or planed) to rename those labels ?
Or is it possible to define a custom env variable that references the add-on's value ?
Like
MY_DB_HOST
= $POSTGRESQL_ADDON_HOST
(I tried this but it takes "$POSTGRESQL_ADDON_HOST" as a string)
That would be a great feature
Any news on this topic? @hsablonniere could you use your magic to make it happen? :sparkles:
+1 it would be awesome to inject global addon variables into local variables. Is it possible now?
To my knowledge, it is still not possible. There is an ugly workaround somewhere, but I don't remember it. By the way @welcoMattic, hsablonniere can't do anything about it, it's because of some variable escaping done in the back-end.
Edit: Ugly workaround is to edit ~/applicationrc
via a script in CC_PRE_RUN_HOOK
.
Environment variables | Clever Cloud Documentation
https://www.clever-cloud.com/doc/develop/env-variables/