3434 steps :
3535 - name : Checkout
3636 uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
37+ with :
38+ persist-credentials : false
3739
3840 - name : Set up Helm
3941 uses : azure/setup-helm@dda3372f752e03dde6b3237bc9431cdc2f7a02a2 # v5.0.0
7880 steps :
7981 - name : Checkout
8082 uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
83+ with :
84+ persist-credentials : false
8185
8286 - name : Set up Helm
8387 uses : azure/setup-helm@dda3372f752e03dde6b3237bc9431cdc2f7a02a2 # v5.0.0
@@ -112,7 +116,7 @@ jobs:
112116 PRERELEASE_VERSION="${BASE_VERSION}-main.${SHORT_SHA}"
113117 else
114118 SHORT_SHA=$(echo "${{ github.sha }}" | cut -c1-7)
115- REF_SLUG=$(echo "${{ github.ref_name } }" | tr '/' '-' | tr -cd 'a-zA-Z0-9-')
119+ REF_SLUG=$(echo "${GITHUB_REF_NAME }" | tr '/' '-' | tr -cd 'a-zA-Z0-9-')
116120 if [[ -z "$REF_SLUG" ]]; then
117121 REF_SLUG="manual"
118122 fi
@@ -123,7 +127,9 @@ jobs:
123127
124128 - name : Update Chart.yaml with prerelease version
125129 run : |
126- sed -i "s/^version:.*/version: ${{ steps.version.outputs.version }}/" ./hosting/k8s/helm/Chart.yaml
130+ sed -i "s/^version:.*/version: ${STEPS_VERSION_OUTPUTS_VERSION}/" ./hosting/k8s/helm/Chart.yaml
131+ env :
132+ STEPS_VERSION_OUTPUTS_VERSION : ${{ steps.version.outputs.version }}
127133
128134 - name : Override appVersion
129135 if : github.event_name == 'workflow_dispatch' && inputs.app_version != ''
@@ -138,26 +144,30 @@ jobs:
138144
139145 - name : Push Helm Chart to GHCR
140146 run : |
141- VERSION="${{ steps.version.outputs.version } }"
147+ VERSION="${STEPS_VERSION_OUTPUTS_VERSION }"
142148 CHART_PACKAGE="/tmp/${{ env.CHART_NAME }}-${VERSION}.tgz"
143149
144150 # Push to GHCR OCI registry
145151 helm push "$CHART_PACKAGE" "oci://${{ env.REGISTRY }}/${{ github.repository_owner }}/charts"
152+ env :
153+ STEPS_VERSION_OUTPUTS_VERSION : ${{ steps.version.outputs.version }}
146154
147155 - name : Write run summary
148156 run : |
149157 {
150158 echo "### 🧭 Helm Chart Prerelease Published"
151159 echo ""
152- echo "**Version:** \`${{ steps.version.outputs.version } }\`"
160+ echo "**Version:** \`${STEPS_VERSION_OUTPUTS_VERSION }\`"
153161 echo ""
154162 echo "**Install:**"
155163 echo '```bash'
156164 echo "helm upgrade --install trigger \\"
157165 echo " oci://${{ env.REGISTRY }}/${{ github.repository_owner }}/charts/${{ env.CHART_NAME }} \\"
158- echo " --version \"${{ steps.version.outputs.version } }\""
166+ echo " --version \"${STEPS_VERSION_OUTPUTS_VERSION }\""
159167 echo '```'
160168 } >> "$GITHUB_STEP_SUMMARY"
169+ env :
170+ STEPS_VERSION_OUTPUTS_VERSION : ${{ steps.version.outputs.version }}
161171
162172 - name : Find existing comment
163173 if : github.event_name == 'pull_request'
0 commit comments