Skip to content

Commit 826d71d

Browse files
authored
Fix workflow triggers for docs updates (#1477)
Signed-off-by: Dan Barr <[email protected]> Co-authored-by: Dan Barr <[email protected]>
1 parent 99b79c2 commit 826d71d

File tree

3 files changed

+34
-3
lines changed

3 files changed

+34
-3
lines changed

.github/workflows/releaser-helm-charts.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ jobs:
1111
packages: write
1212
id-token: write
1313

14+
outputs:
15+
chart_version: ${{ steps.chart-releaser.outputs.chart_version }}
16+
1417
steps:
1518
- name: Checkout
1619
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
@@ -23,6 +26,7 @@ jobs:
2326
git config user.email "[email protected]"
2427
2528
- name: Run chart-releaser
29+
id: chart-releaser
2630
uses: helm/chart-releaser-action@cae68fefc6b5f367a0275617c9f83181ba54714f # v1.7.0
2731
with:
2832
config: cr.yaml
@@ -52,3 +56,13 @@ jobs:
5256
done
5357
env:
5458
COSIGN_EXPERIMENTAL: 1
59+
60+
update-docs-website:
61+
name: Trigger Docs Update
62+
needs: [ release ]
63+
permissions: {}
64+
uses: ./.github/workflows/update-docs-website.yml
65+
with:
66+
version: ${{ needs.release.outputs.chart_version }}
67+
secrets:
68+
DOCS_REPO_DISPATCH_TOKEN: ${{ secrets.DOCS_REPO_DISPATCH_TOKEN }}

.github/workflows/releaser.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,16 @@ jobs:
114114
id-token: write
115115
uses: ./.github/workflows/image-build-and-publish.yml
116116

117+
update-docs-website:
118+
name: Trigger Docs Update
119+
needs: [ release ]
120+
permissions: {}
121+
uses: ./.github/workflows/update-docs-website.yml
122+
with:
123+
version: ${{ github.ref_name }}
124+
secrets:
125+
DOCS_REPO_DISPATCH_TOKEN: ${{ secrets.DOCS_REPO_DISPATCH_TOKEN }}
126+
117127
# provenance:
118128
# name: Generate provenance (SLSA3)
119129
# needs:

.github/workflows/update-docs-website.yml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,15 @@ name: Trigger Docs Update
33
permissions: {}
44

55
on:
6-
release:
7-
types: [published]
6+
workflow_call:
7+
inputs:
8+
version:
9+
description: 'Version tag for the release'
10+
required: true
11+
type: string
12+
secrets:
13+
DOCS_REPO_DISPATCH_TOKEN:
14+
required: true
815

916
jobs:
1017
trigger:
@@ -15,7 +22,7 @@ jobs:
1522
run: |
1623
repo="stacklok/docs-website"
1724
event_type="published-release"
18-
version="${{ github.event.release.tag_name }}"
25+
version="${{ inputs.version }}"
1926
2027
echo "Triggering docs update for $repo with version $version"
2128

0 commit comments

Comments
 (0)