Linux/Ubuntu Set Environment Variable

September 15, 2020
export RUNTIME_API_URL=http://localhost:3000

For permanent environment variable after restart

  • You can set the environment variable via script before running the code/program
  • via ~/.bashrc (or /home/USER/.bashrc). Make sure to target the user used to run the code/program.
This work is licensed under a
Creative Commons Attribution-NonCommercial 4.0 International License.