Skip to content

Commit d8a6999

Browse files
committed
Change main CI workflow, use workflow_run to trigger "stackhpc", "extra", and "trivyscan" workflows.
Expecting this to allow quicker re-runs of failed workflows where we currently have to wait until the CI has finished before we can re-run a failure.
1 parent c12ec99 commit d8a6999

File tree

4 files changed

+18
-9
lines changed

4 files changed

+18
-9
lines changed

.github/workflows/extra.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,11 @@
66

77
name: Test extra build
88
on:
9-
workflow_call:
109
workflow_dispatch:
10+
workflow_run:
11+
workflows: ["extra"]
12+
types:
13+
- completed
1114

1215
permissions:
1316
contents: read

.github/workflows/main.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -127,23 +127,23 @@ jobs:
127127
needs: files_changed
128128
if: |
129129
needs.files_changed.outputs.stackhpc == 'true'
130-
uses: ./.github/workflows/stackhpc.yml
131-
secrets: inherit
130+
# No-op job to trigger workflow 'stackhpc.yml' via workflow_run
131+
uses: mattdesl/no-op@32ec85ff176f761f607087006bda993440da5fe4
132132

133133
extra:
134134
name: Test extra build
135135
needs: files_changed
136136
if: |
137137
github.event_name != 'pull_request' && needs.files_changed.outputs.extra_on_push == 'true' ||
138138
github.event_name == 'pull_request' && needs.files_changed.outputs.extra_on_pull_request == 'true'
139-
uses: ./.github/workflows/extra.yml
140-
secrets: inherit
139+
# No-op job to trigger workflow 'extra.yml' via workflow_run
140+
uses: mattdesl/no-op@32ec85ff176f761f607087006bda993440da5fe4
141141

142142
trivyscan:
143143
name: Trivy scan image for vulnerabilities
144144
needs: files_changed
145145
if: |
146146
github.event_name == 'pull_request' &&
147147
needs.files_changed.outputs.trivyscan == 'true'
148-
uses: ./.github/workflows/trivyscan.yml
149-
secrets: inherit
148+
# No-op job to trigger workflow 'trivyscan.yml' via workflow_run
149+
uses: mattdesl/no-op@32ec85ff176f761f607087006bda993440da5fe4

.github/workflows/stackhpc.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,11 @@
66

77
name: Test deployment and reimage on OpenStack
88
on:
9-
workflow_call:
109
workflow_dispatch:
10+
workflow_run:
11+
workflows: ["stackhpc"]
12+
types:
13+
- completed
1114

1215
permissions:
1316
contents: read

.github/workflows/trivyscan.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,11 @@
66

77
name: Trivy scan image for vulnerabilities
88
on:
9-
workflow_call:
109
workflow_dispatch:
10+
workflow_run:
11+
workflows: ["trivyscan"]
12+
types:
13+
- completed
1114

1215
permissions:
1316
contents: read

0 commit comments

Comments
 (0)