Defining environment variables for external dependencies with Skogsra

Hello guys, I’m currently using Skogsra for setting up environment variables. So far the variables that are used on our code work as intended, however I’ve been wondering if external libraries (dependencies) are able to leverage their environment variables using Skogsra. The thing is, libraries usually use Application.get_env/2 to obtain some variable that is needed, so I believe those variable have to exist on either of the config files for the specified environment, so that makes me feel that using Skogsra is only used for fetching environment variables from my own codebase, so it won’t apply for libraries. If you know something about it, please let me know, I would like to solve this doubt.

Personally I stick to using system env variables only for production deployments and therefore just have a bunch of System.get_env / System.fetch_env! calls in runtime.exs.

2 Likes