-
Notifications
You must be signed in to change notification settings - Fork 26
47 lines (46 loc) · 1.29 KB
/
build-action.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
39
40
41
42
43
44
45
46
47
name: build
# This workflow is triggered on pushes to the repository.
on: [push, pull_request]
jobs:
build:
name: build-job
runs-on: ubuntu-latest
steps:
- name: Slack Notify Build
continue-on-error: true
uses: voxmedia/github-action-slack-notify-build@v1.1.2
id: slack
with:
channel: ci
status: STARTED
color: good
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_NOTIFICATIONS_BOT_TOKEN }}
- name: Checkout repo
uses: actions/checkout@v2
- name: Test
run: make test
- name: Docker Build
run: make build
- name: Notify Slack Success
continue-on-error: true
if: success()
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_NOTIFICATIONS_BOT_TOKEN }}
uses: voxmedia/github-action-slack-notify-build@v1.1.2
with:
message_id: ${{ steps.slack.outputs.message_id }}
channel: ci
status: SUCCESS
color: good
- name: Notify Slack Fail
continue-on-error: true
if: failure()
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_NOTIFICATIONS_BOT_TOKEN }}
uses: voxmedia/github-action-slack-notify-build@v1.1.2
with:
message_id: ${{ steps.slack.outputs.message_id }}
channel: ci
status: FAILED
color: danger