-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deploy only if there are no syntax errors
- Loading branch information
1 parent
c53ddd4
commit 21a4c7b
Showing
1 changed file
with
13 additions
and
3 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,25 @@ | ||
name: Deploy to Render | ||
|
||
on: | ||
push: | ||
branches: [ main ] | ||
workflow_run: | ||
workflows: [Check for syntax errors] | ||
types: [completed] | ||
branches: [main] | ||
|
||
jobs: | ||
build: | ||
deploy-to-render: | ||
runs-on: ubuntu-latest | ||
if: ${{ github.event.workflow_run.conclusion == 'success' }} | ||
|
||
steps: | ||
- name: Deploy to production | ||
uses: johnbeynon/render-deploy-action@v0.0.8 | ||
with: | ||
service-id: ${{ secrets.MY_RENDER_SERVICE_ID }} | ||
api-key: ${{ secrets.MY_RENDER_API_KEY }} | ||
|
||
on-failure: | ||
runs-on: ubuntu-latest | ||
if: ${{ github.event.workflow_run.conclusion == 'failure' }} | ||
steps: | ||
- run: echo 'The triggering workflow failed' |