Updating System Environment Variables without restarting release

Am running a phoenix api built with mix releases, setup mostly uses system environments variables for configuration, is there a way to reload the system to effect new config when i update system variables, without having to stop the phoenix server?
Currenlty i have to restart the phoenix server for the variables to apply.

No, not really. Especially when you edit that environment variables outside the process. You cannot edit environment variables of running process (at least without superuser hacks on Linux, I do not know if it is possible at all on BSD systems). However you can use System.put_env/2 and Application.put_env/{3,4} within BEAM instance to change configuration options.


Ahh, thanks mahn! Used System.put_env/2, hadn’t thought of that.
Thanks again.