generated from hackforla/.github-hackforla-base-repo-template
-
-
Notifications
You must be signed in to change notification settings - Fork 4
39 lines (33 loc) · 1.29 KB
/
notify-failed-build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Notify Docker build success or failure
on:
workflow_run:
workflows: ["Publish Docker Image"]
types:
- completed
jobs:
on-failure:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Open issue
run: gh issue create
--repo github.com/hackforla/ops
--title "GHPAGES-DOCKER Build Has Failed"
--body "A recently triggered **build-and-push-to-docker-hub** workflow in the [ghpages-docker repo](https://github.com/hackforla/ghpages-docker) has failed."
env:
GH_TOKEN: ${{ secrets.Daniel_Ridge_PAT }}
on-success:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Open issue
run: gh issue create
--repo github.com/hackforla/ops
--title "GHPAGES-DOCKER Build Was Successful"
--body "A recently triggered **build-and-push-to-docker-hub** workflow in the [ghpages-docker repo](https://github.com/hackforla/ghpages-docker) has completed successfully."
env:
GH_TOKEN: ${{ secrets.Daniel_Ridge_PAT }}