Skip to content

Instantly share code, notes, and snippets.

@sgoley
Last active June 19, 2020 13:17
Show Gist options
  • Save sgoley/7ff3383f87109f65c818cd8a7288ce5b to your computer and use it in GitHub Desktop.
Save sgoley/7ff3383f87109f65c818cd8a7288ce5b to your computer and use it in GitHub Desktop.
Heroku: Copying environment variables from an existing app to another
1. Export existing app’s variables to config.txt
heroku config -s -a existing-heroku-app > config.txt
2. Review and push to another app
cat config.txt | tr '\n' ' ' | xargs heroku config:set -a new-heroku-app
Credit: https://emirkarsiyakali.com/@EmirKarsiyakali
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment