Skip to content

Commit

Permalink
Fix the Heroku deploy payload (#49)
Browse files Browse the repository at this point in the history
The payload structure was modified by #46. Also adds some logs so we can
better understand what is happening
  • Loading branch information
Lothiraldan authored and La0 committed Jul 5, 2019
1 parent 3901776 commit d64517a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion taskboot/push.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,9 @@ def heroku_release(target, args):
# Trigger a release on Heroku
logger.info("Deploying update for dyno types: %r", list(sorted(x["type"] for x in updates_payload)))

updates_payload = {"updates": updates_payload}
logger.debug("Using payload: %r", updates_payload)

r = requests.patch(
f'https://api.heroku.com/apps/{args.heroku_app}/formation',
json=updates_payload,
Expand All @@ -138,6 +141,7 @@ def heroku_release(target, args):
'Authorization': f"Bearer {config.heroku['password']}",
},
)
logger.debug("Heroku deployment answer: %s", r.text)
r.raise_for_status()

logger.info(f'The {args.heroku_app}/{args.heroku_dyno_name} application has been updated')
logger.info(f'The {args.heroku_app} application has been updated')

0 comments on commit d64517a

Please sign in to comment.