-
Notifications
You must be signed in to change notification settings - Fork 136
32 lines (31 loc) · 1.13 KB
/
notify-docker-available.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
name: Docker Available
on: status
jobs:
check:
runs-on: ubuntu-latest
steps:
- name: Dump Github context
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
run: echo "$GITHUB_CONTEXT"
- name: Checkout
if: endsWith(github.event.context, 'docker_build') && github.event.state == 'success'
uses: actions/checkout@v2
- name: Setup Python
if: endsWith(github.event.context, 'docker_build') && github.event.state == 'success'
uses: actions/setup-python@v1
with:
python-version: '3.7'
- name: Run Notify Script
if: endsWith(github.event.context, 'docker_build') && github.event.state == 'success'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
echo "==== $(date): Starting pipenv setup... ===="
python -m pip install --upgrade pip
pip install pipenv
pwd
cd "$GITHUB_WORKSPACE/.github/workflows/notify-docker-available"
pipenv install
echo "==== $(date): Running notify... ===="
pipenv run ./notify.py -e "$GITHUB_EVENT_PATH"