File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change 16
16
env :
17
17
# Only to avoid some repetition
18
18
FLAKE_REF : github:${{ github.repository }}/${{ github.ref_name }}
19
+ GH_TOKEN : ${{ github.token }}
19
20
# We need to tell skopeo where to write the authentication token
20
21
REGISTRY_AUTH_FILE : ./skopeo-registry-auth-file.json
21
22
22
23
jobs :
24
+ wait-for-hydra :
25
+ name : " Wait for hydra check-runs"
26
+ runs-on : ubuntu-latest
27
+ steps :
28
+ - name : Waiting for ci/hydra-build:required to complete
29
+ run : |
30
+ while [[ true ]]; do
31
+ conclusion=$(gh api repos/$GITHUB_REPOSITORY/commits/$GITHUB_SHA/check-runs --jq '.check_runs[] | select(.name == "ci/hydra-build:required") | .conclusion')
32
+ case "$conclusion" in
33
+ success)
34
+ echo "ci/hydra-build:required succeeded"
35
+ exit 0;;
36
+ failure)
37
+ echo "ci/hydra-build:required failed"
38
+ exit 1;;
39
+ *)
40
+ echo "ci/hydra-build:required pending. Waiting 30s..."
41
+ sleep 30;;
42
+ esac
43
+ done
44
+
23
45
build :
46
+ needs : [wait-for-hydra]
24
47
name : " Upload to ghcr.io"
25
48
runs-on : ubuntu-latest
26
49
steps :
You can’t perform that action at this time.
0 commit comments