Skip to content

Commit 7b80ae2

Browse files
committed
feat: add heroku
1 parent 8e8f022 commit 7b80ae2

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

.github/workflows/main.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,3 +59,22 @@ jobs:
5959
branch: ${{ github.head_ref || github.ref_name }}
6060
env:
6161
GITHUB_TOKEN: ${{secrets.ACCESS_TOKEN}}
62+
heroku:
63+
if: github.repository == 'devsecopsmaturitymodel/DevSecOps-MaturityModel' && github.event_name == 'push' && github.ref == 'refs/heads/master'
64+
runs-on: ubuntu-latest
65+
steps:
66+
- name: "Check out Git repository"
67+
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac #v4.0.0
68+
- name: "Set Heroku app & branch for ${{ github.ref }}"
69+
run: |
70+
if [ "$GITHUB_REF" == "refs/heads/master" ]; then
71+
echo "HEROKU_APP=dsomm" >> $GITHUB_ENV
72+
echo "HEROKU_BRANCH=master" >> $GITHUB_ENV
73+
fi
74+
- name: "Deploy ${{ github.ref }} to Heroku"
75+
uses: akhileshns/heroku-deploy@9fd0f9faae4aa93a38d6f5e25b9128589f1371b0 #v3.12.14
76+
with:
77+
heroku_api_key: ${{ secrets.HEROKU_API_KEY }}
78+
heroku_app_name: ${{ env.HEROKU_APP }}
79+
heroku_email: timo.pagel@owasp.org
80+
branch: ${{ env.HEROKU_BRANCH }}

0 commit comments

Comments
 (0)