Repository navigation
Expand file tree
/
Copy pathaction-trigger-docker-build.yml
More file actions
57 lines (53 loc) · 1.83 KB
/
Copy pathaction-trigger-docker-build.yml
File metadata and controls
57 lines (53 loc) · 1.83 KB
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
name: Trigger Docker Build
on:
workflow_dispatch:
release:
types:
- published
permissions: {}
jobs:
trigger_build_docker-linuxgsm:
if: github.repository_owner == 'GameServerManagers'
name: Trigger Build Docker LinuxGSM
runs-on: ubuntu-latest
steps:
- name: Trigger Workflow and Wait (linuxgsm)
env:
GH_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
run: |
before=$(date -u +%Y-%m-%dT%H:%M:%SZ)
gh workflow run action-docker-publish.yml --repo GameServerManagers/docker-linuxgsm
sleep 10
run_id=$(gh run list \
--workflow action-docker-publish.yml \
--repo GameServerManagers/docker-linuxgsm \
--created ">=${before}" \
--limit 1 \
--json databaseId \
--jq '.[0].databaseId')
gh run watch "${run_id}" \
--repo GameServerManagers/docker-linuxgsm \
--exit-status
trigger_build_docker-gameserver:
if: github.repository_owner == 'GameServerManagers'
name: Trigger Build Docker GameServer
needs: trigger_build_docker-linuxgsm
runs-on: ubuntu-latest
steps:
- name: Trigger Workflow and Wait (gameserver)
env:
GH_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
run: |
before=$(date -u +%Y-%m-%dT%H:%M:%SZ)
gh workflow run action-docker-publish.yml --repo GameServerManagers/docker-gameserver
sleep 10
run_id=$(gh run list \
--workflow action-docker-publish.yml \
--repo GameServerManagers/docker-gameserver \
--created ">=${before}" \
--limit 1 \
--json databaseId \
--jq '.[0].databaseId')
gh run watch "${run_id}" \
--repo GameServerManagers/docker-gameserver \
--exit-status