Skip to content

Commit 4b0013b

Browse files
committed
Add manual trigger and improve attestation for testing
1 parent aa6d08b commit 4b0013b

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

.github/workflows/release.yaml

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@ on:
66
- main
77
paths:
88
- 'charts/atlantis/**'
9+
workflow_dispatch:
10+
inputs:
11+
chart_version:
12+
description: 'Chart version to release (optional, will use Chart.yaml version if not provided)'
13+
required: false
14+
type: string
915

1016
permissions: read-all
1117

@@ -54,8 +60,15 @@ jobs:
5460
helm package charts/atlantis
5561
helm push atlantis-*.tgz oci://ghcr.io/${GITHUB_REPOSITORY_OWNER}/charts
5662
63+
- name: Get chart info
64+
id: chart-info
65+
run: |
66+
CHART_VERSION=$(yq e '.version' charts/atlantis/Chart.yaml)
67+
echo "version=${CHART_VERSION}" >> $GITHUB_OUTPUT
68+
echo "subject-name=ghcr.io/${{ github.repository_owner }}/charts/atlantis:${CHART_VERSION}" >> $GITHUB_OUTPUT
69+
5770
- name: Attest chart OCI artifact
5871
uses: actions/attest-build-provenance@v3
5972
with:
60-
subject-name: ghcr.io/${{ github.repository_owner }}/charts/atlantis:$(yq e '.version' charts/atlantis/Chart.yaml)
73+
subject-name: ${{ steps.chart-info.outputs.subject-name }}
6174
push-to-registry: true

0 commit comments

Comments
 (0)