Skip to content

Instantly share code, notes, and snippets.

@namhnz
Created August 17, 2019 16:31
Show Gist options
  • Save namhnz/3d682c39845d299f69a424866ccd41fe to your computer and use it in GitHub Desktop.
Save namhnz/3d682c39845d299f69a424866ccd41fe to your computer and use it in GitHub Desktop.
# from http://blog.federicosilva.net/
version: 2
jobs:
build:
branches:
only:
- master
machine: true
steps:
# checkout source code
- checkout
# build image
- run: |
docker info
docker build -t daycare-app .
# deploy the image
- run: |
docker login --username=$HEROKU_USERNAME --password=$HEROKU_API_KEY registry.heroku.com
docker tag daycare-app registry.heroku.com/$HEROKU_APP_NAME/web
docker push registry.heroku.com/$HEROKU_APP_NAME/web
# release the image
- run: |
heroku -v
heroku update
heroku container:release web -a $HEROKU_APP_NAME
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment