Install heroku CLI #22
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy | |
on: | |
push: | |
branches: [ 'staging', 'heroku-docker' ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Install Heroku CLI | |
run: | | |
curl https://cli-assets.heroku.com/install.sh | sh | |
- name: Login to Heroku container registry | |
run: | | |
cat >~/.netrc <<EOF | |
machine api.heroku.com | |
login ${{ secrets.HEROKU_API_EMAIL }} | |
password ${{ secrets.HEROKU_API_KEY }} | |
machine git.heroku.com | |
login ${{ secrets.HEROKU_API_EMAIL }} | |
password ${{ secrets.HEROKU_API_KEY }} | |
EOF | |
heroku container:login | |
- name: Push containers to Heroku | |
run: | | |
heroku container:push web worker --recursive \ | |
--app staging-partner-tools \ | |
--arg BUNDLE_GEM__FURY__IO=${{ secrets.BUNDLE_GEM__FURY__IO }},BUNDLE_GITHUB__COM=${{ secrets.BUNDLE_GITHUB__COM }},BUNDLE_GEMS__RAILSLTS__COM=${{ secrets.BUNDLE_GEMS__RAILSLTS__COM }} | |
- name: Release containers to Heroku | |
run: 'heroku container:release web worker --app staging-partner-tools' |