Skip to content

Commit a7e5575

Browse files
authored
Add checkout step and build dispatch payload
1 parent f5a72cf commit a7e5575

1 file changed

Lines changed: 16 additions & 2 deletions

File tree

‎.github/workflows/build.yaml‎

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,10 +170,24 @@ jobs:
170170
run: |
171171
docker buildx imagetools inspect ghcr.io/${{ vars.ORG_REPO }}/${{ github.event.repository.name }}:latest
172172
173+
- name: checkout
174+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
175+
176+
- name: Build dispatch payload
177+
id: payload
178+
env:
179+
REPO: ${{ github.event.repository.name }}
180+
TAG: ${{ needs.build.outputs.tag }}
181+
run: |
182+
payload=$(yq -o=json '.' web-meta.yaml \
183+
| jq -c --arg repo "$REPO" --arg tag "$TAG" \
184+
'{repo: $repo, tag: $tag, meta: .}')
185+
echo "json=$payload" >> "$GITHUB_OUTPUT"
186+
173187
- name: Post version update to dash
174188
uses: peter-evans/repository-dispatch@28959ce8df70de7be546dd1250a005dd32156697 # v4.0.1
175189
with:
176190
token: ${{ secrets.BUILD_TOKEN }}
177191
repository: ccpbiosim/ccpbiosim.github.io
178-
event-type: workshops
179-
client-payload: '{"repo": "${{ github.event.repository.name }}", "tag": "${{ needs.build.outputs.tag }}"}'
192+
event-type: workshops
193+
client-payload: ${{ steps.payload.outputs.json }}

0 commit comments

Comments
 (0)