-
Notifications
You must be signed in to change notification settings - Fork 3
82 lines (62 loc) · 1.91 KB
/
example_needle.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# File: example_needle.yml
# Author: Ryoichi Ando ([email protected])
# License: Apache v2.0
name: needle.ipynb
on:
workflow_dispatch:
inputs:
runner:
type: string
required: true
description: 'Runner Name'
env:
VAST_API_KEY: ${{ secrets.VAST_API_KEY }}
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
EXAMPLE_NAME: needle
HELPER_PATH: .github/workflows/vast/helper.sh
jobs:
run:
runs-on: ${{ github.event.inputs.runner }}
steps:
- name: check out repo
uses: actions/checkout@v3
- name: print scene
run: |
echo "Scene: $EXAMPLE_NAME" >> $GITHUB_STEP_SUMMARY
- name: prepare
timeout-minutes: 20
run: bash $HELPER_PATH create $VAST_API_KEY
- name: 1st run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 2nd run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 3rd run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 4th run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 5th run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 6th run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 7th run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 8th run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 9th run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: 10th run
run: bash $HELPER_PATH run ${EXAMPLE_NAME}.py
- name: shutdown
if: always()
run: bash $HELPER_PATH delete
notify_failure:
runs-on: ${{ github.event.inputs.runner }}
needs: run
if: ${{ failure() }}
steps:
- name: Slack Notification Failure
uses: rtCamp/action-slack-notify@v2
env:
SLACK_TITLE: Deploy / Failure
SLACK_COLOR: danger
SLACK_MESSAGE: One or more tests failed.