From e46d5f825cd8fddb309651571c62650c45dc8c6d Mon Sep 17 00:00:00 2001 From: Michael Johnson Date: Wed, 13 Jan 2021 09:44:26 -0700 Subject: [PATCH] Update ruby.yml --- .github/workflows/ruby.yml | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index d8fcd27..f498f31 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -46,20 +46,28 @@ jobs: if: ${{github.ref == 'ref/head/master'}} runs-on: ubuntu-latest steps: + - name: start deployment + uses: bobheadxi/deployments@v0.4.3 + id: deployment + with: + step: start + token: ${{ secrets.GITHUB_TOKEN }} + env: production - uses: actions/checkout@v2 - uses: akhileshns/heroku-deploy@v3.8.9 # This is the action with: heroku_api_key: ${{secrets.HEROKU_API_KEY}} heroku_app_name: "migarjo-ruby-books" #Must be unique in Heroku heroku_email: "mjohn174@gmail.com" - - name: Update result to Deployment API + - name: update deployment status + uses: bobheadxi/deployments@v0.4.3 if: always() - uses: unacast/actions-github-deployment-status@0.4.0 with: - github_token: ${{ secrets.GITHUB_TOKEN }} + step: finish + token: ${{ secrets.GITHUB_TOKEN }} status: ${{ job.status }} - description: "Deployed to Production" - environment_url: "https://migarjo-ruby-books.herokuapp.com/" + env_url: "https://migarjo-ruby-books.herokuapp.com/" + deployment_id: ${{ steps.deployment.outputs.deployment_id }} deploy-to-review: name: Deploy to Heroku Review if: ${{github.ref != 'ref/head/master'}} @@ -71,7 +79,7 @@ jobs: with: step: start token: ${{ secrets.GITHUB_TOKEN }} - env: release + env: review - uses: actions/checkout@v2 - uses: akhileshns/heroku-deploy@v3.8.9 # This is the action with: @@ -85,5 +93,5 @@ jobs: step: finish token: ${{ secrets.GITHUB_TOKEN }} status: ${{ job.status }} - env_url: "https://migarjo-ruby-books.herokuapp.com/" + env_url: "https://migarjo-ruby-books-review.herokuapp.com/" deployment_id: ${{ steps.deployment.outputs.deployment_id }}