-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (46 loc) · 1.35 KB
/
main.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
48
49
50
51
52
53
54
55
name: "Test and build notification scripts."
on:
push:
branches:
- main
tags-ignore:
- '*.*.*'
pull_request:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: '3.8'
- name: Run unit tests
run: |
pip install -r requirements.tests.txt
pytest tests/ --junitxml=test-report.xml -v
- name: Multi-arch docker image build prerequired
run: sudo docker run --privileged linuxkit/binfmt:v0.7
- name: Build and deploy on architecture
env:
SIXSQ_DOCKER_USERNAME: ${{ secrets.SIXSQ_DOCKER_USERNAME }}
SIXSQ_DOCKER_PASSWORD: ${{ secrets.SIXSQ_DOCKER_PASSWORD }}
run: ./container-release.sh
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v1
if: always()
with:
files: test-report.xml
notify:
if: always()
name: Post Workflow Status To Slack
needs:
- build
runs-on: ubuntu-latest
steps:
- name: Slack Workflow Notification
uses: Gamesight/slack-workflow-status@master
with:
repo_token: ${{secrets.GITHUB_TOKEN}}
slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}}
icon_emoji: ':rocket:'