Skip to content

Instantly share code, notes, and snippets.

@kubek2k
Created January 9, 2019 11:49
Show Gist options
  • Save kubek2k/69aa2d4d91eb63b062c318774f89dd4d to your computer and use it in GitHub Desktop.
Save kubek2k/69aa2d4d91eb63b062c318774f89dd4d to your computer and use it in GitHub Desktop.
for a in `heroku list -t omni | tail -n +2 | awk '{ print $1 }'`; do
count=`heroku ps -a $a --json | jq '[.[] | select(.type == "web")] | length' | tr -d '\n'`
if [ "$count" == "1" ]; then
heroku features:enable preboot -a $a
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment