Skip to content

Instantly share code, notes, and snippets.

@wichopy
Created July 1, 2018 14:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wichopy/2e5a2292a9315c4430580e4bfe017297 to your computer and use it in GitHub Desktop.
Save wichopy/2e5a2292a9315c4430580e4bfe017297 to your computer and use it in GitHub Desktop.
PM2 start npm script with environment variables injected.
pm2 start npm --name [process name] -- run [npm script name] ENV_VAR=some_env_var_value
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment