Skip to content

Commit c6ac7f1

Browse files
authored
structure better
1 parent a26d2c8 commit c6ac7f1

File tree

1 file changed

+17
-19
lines changed

1 file changed

+17
-19
lines changed

.github/workflows/on-droneci-complete.yml

Lines changed: 17 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,51 +7,49 @@ on:
77
description: "equivalent to github.sha in an ordinary workflow"
88
required: true
99
success:
10-
description: "did drone tests pass or did they fail?"
10+
description: "did drone tests pass or fail?"
1111
required: true
1212
type: boolean
1313

1414
jobs:
15-
on-droneci-complete:
15+
# This one should pass
16+
cms-followup:
1617
runs-on: ubuntu-24.04
18+
# uses: ./.github/workflows/cms-followup.yml
1719
steps:
1820
- run: |
19-
echo "Triggered by Drone commit: ${{ inputs.github_sha }}"
20-
21-
k8s-followup-thing:
22-
runs-on: ubuntu-24.04
23-
needs: on-droneci-complete
24-
steps:
25-
# probably a uses: invocation IRL
26-
- name: invoke workflow
27-
run: |
28-
echo "This step should fail"
29-
false
21+
echo "Triggered by Drone commit: ${{ inputs.github_sha }} on branch ${{ github.ref }}"
22+
echo "This step should succeed"
23+
true
3024
25+
# Need to do this manually or the result won't be visible within the PR
3126
- uses: actions/github-script@v7
3227
with:
3328
script: |
3429
await github.rest.repos.createCommitStatus({
35-
context: 'K8S Followup Thing',
30+
context: 'CMS Followup',
3631
owner: context.repo.owner,
3732
repo: context.repo.repo,
3833
sha: '${{ inputs.github_sha }}',
3934
state: '${{ job.status == 'success' && "success" || "failure" }}',
4035
})
4136
42-
cms-followup-thing:
37+
# This one should fail
38+
k8s-followup:
4339
runs-on: ubuntu-24.04
44-
needs: on-droneci-complete
40+
# uses: ./.github/workflows/k8s-followup.yml
4541
steps:
4642
- run: |
47-
echo "This step should succeed"
48-
true
43+
echo "Triggered by Drone commit: ${{ inputs.github_sha }} on branch ${{ github.ref }}"
44+
echo "This step should fail"
45+
false
4946
47+
# Need to do this manually or the result won't be visible within the PR
5048
- uses: actions/github-script@v7
5149
with:
5250
script: |
5351
await github.rest.repos.createCommitStatus({
54-
context: 'CMS Followup Thing',
52+
context: 'K8S Followup',
5553
owner: context.repo.owner,
5654
repo: context.repo.repo,
5755
sha: '${{ inputs.github_sha }}',

0 commit comments

Comments
 (0)