|
23 | 23 | required: true |
24 | 24 | type: boolean |
25 | 25 | default: false |
| 26 | + publish_gha_runner_scale_set_controller_experimental_chart: |
| 27 | + description: "Publish new helm chart for gha-runner-scale-set-controller-experimental" |
| 28 | + required: true |
| 29 | + type: boolean |
| 30 | + default: false |
26 | 31 | publish_gha_runner_scale_set_chart: |
27 | 32 | description: "Publish new helm chart for gha-runner-scale-set" |
28 | 33 | required: true |
29 | 34 | type: boolean |
30 | 35 | default: false |
| 36 | + publish_gha_runner_scale_set_experimental_chart: |
| 37 | + description: "Publish new helm chart for gha-runner-scale-set-experimental" |
| 38 | + required: true |
| 39 | + type: boolean |
| 40 | + default: false |
31 | 41 |
|
32 | 42 | env: |
33 | 43 | HELM_VERSION: v3.8.0 |
@@ -159,6 +169,54 @@ jobs: |
159 | 169 | echo "- Short SHA: ${{ steps.resolve_parameters.outputs.short_sha }}" >> $GITHUB_STEP_SUMMARY |
160 | 170 | echo "- gha-runner-scale-set-controller Chart version: ${{ env.GHA_RUNNER_SCALE_SET_CONTROLLER_CHART_VERSION_TAG }}" >> $GITHUB_STEP_SUMMARY |
161 | 171 |
|
| 172 | + publish-helm-chart-gha-runner-scale-set-controller-experimental: |
| 173 | + if: ${{ inputs.publish_gha_runner_scale_set_controller_experimental_chart == true }} |
| 174 | + needs: build-push-image |
| 175 | + name: Publish Helm chart for gha-runner-scale-set-controller-experimental |
| 176 | + runs-on: ubuntu-latest |
| 177 | + steps: |
| 178 | + - name: Checkout |
| 179 | + uses: actions/checkout@v6 |
| 180 | + with: |
| 181 | + # If inputs.ref is empty, it'll resolve to the default branch |
| 182 | + ref: ${{ inputs.ref }} |
| 183 | + |
| 184 | + - name: Resolve parameters |
| 185 | + id: resolve_parameters |
| 186 | + run: | |
| 187 | + resolvedRef="${{ inputs.ref }}" |
| 188 | + if [ -z "$resolvedRef" ] |
| 189 | + then |
| 190 | + resolvedRef="${{ github.ref }}" |
| 191 | + fi |
| 192 | + echo "resolved_ref=$resolvedRef" >> $GITHUB_OUTPUT |
| 193 | + echo "INFO: Resolving short SHA for $resolvedRef" |
| 194 | + echo "short_sha=$(git rev-parse --short $resolvedRef)" >> $GITHUB_OUTPUT |
| 195 | + echo "INFO: Normalizing repository name (lowercase)" |
| 196 | + echo "repository_owner=$(echo ${{ github.repository_owner }} | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT |
| 197 | +
|
| 198 | + - name: Set up Helm |
| 199 | + uses: azure/setup-helm@1a275c3b69536ee54be43f2070a358922e12c8d4 |
| 200 | + with: |
| 201 | + version: ${{ env.HELM_VERSION }} |
| 202 | + |
| 203 | + - name: Publish new helm chart for gha-runner-scale-set-controller-experimental |
| 204 | + run: | |
| 205 | + echo ${{ secrets.GITHUB_TOKEN }} | helm registry login ghcr.io --username ${{ github.actor }} --password-stdin |
| 206 | + GHA_RUNNER_SCALE_SET_CONTROLLER_CHART_VERSION_TAG=$(cat charts/gha-runner-scale-set-controller-experimental/Chart.yaml | grep version: | cut -d " " -d '"' -f 2) |
| 207 | + echo "GHA_RUNNER_SCALE_SET_CONTROLLER_CHART_VERSION_TAG=${GHA_RUNNER_SCALE_SET_CONTROLLER_CHART_VERSION_TAG}" >> $GITHUB_ENV |
| 208 | + helm package charts/gha-runner-scale-set-controller-experimental/ --version="${GHA_RUNNER_SCALE_SET_CONTROLLER_CHART_VERSION_TAG}" |
| 209 | + helm push gha-runner-scale-set-controller-experimental-"${GHA_RUNNER_SCALE_SET_CONTROLLER_CHART_VERSION_TAG}".tgz oci://ghcr.io/${{ steps.resolve_parameters.outputs.repository_owner }}/actions-runner-controller-charts |
| 210 | +
|
| 211 | + - name: Job summary |
| 212 | + run: | |
| 213 | + echo "New helm chart for gha-runner-scale-set-controller-experimental published successfully!" >> $GITHUB_STEP_SUMMARY |
| 214 | + echo "" >> $GITHUB_STEP_SUMMARY |
| 215 | + echo "**Parameters:**" >> $GITHUB_STEP_SUMMARY |
| 216 | + echo "- Ref: ${{ steps.resolve_parameters.outputs.resolved_ref }}" >> $GITHUB_STEP_SUMMARY |
| 217 | + echo "- Short SHA: ${{ steps.resolve_parameters.outputs.short_sha }}" >> $GITHUB_STEP_SUMMARY |
| 218 | + echo "- gha-runner-scale-set-controller-experimental Chart version: ${{ env.GHA_RUNNER_SCALE_SET_CONTROLLER_CHART_VERSION_TAG }}" >> $GITHUB_STEP_SUMMARY |
| 219 | +
|
162 | 220 | publish-helm-chart-gha-runner-scale-set: |
163 | 221 | if: ${{ inputs.publish_gha_runner_scale_set_chart == true }} |
164 | 222 | needs: build-push-image |
@@ -206,3 +264,52 @@ jobs: |
206 | 264 | echo "- Ref: ${{ steps.resolve_parameters.outputs.resolvedRef }}" >> $GITHUB_STEP_SUMMARY |
207 | 265 | echo "- Short SHA: ${{ steps.resolve_parameters.outputs.short_sha }}" >> $GITHUB_STEP_SUMMARY |
208 | 266 | echo "- gha-runner-scale-set Chart version: ${{ env.GHA_RUNNER_SCALE_SET_CHART_VERSION_TAG }}" >> $GITHUB_STEP_SUMMARY |
| 267 | +
|
| 268 | + publish-helm-chart-gha-runner-scale-set-experimental: |
| 269 | + if: ${{ inputs.publish_gha_runner_scale_set_experimental_chart == true }} |
| 270 | + needs: build-push-image |
| 271 | + name: Publish Helm chart for gha-runner-scale-set-experimental |
| 272 | + runs-on: ubuntu-latest |
| 273 | + steps: |
| 274 | + - name: Checkout |
| 275 | + uses: actions/checkout@v6 |
| 276 | + with: |
| 277 | + # If inputs.ref is empty, it'll resolve to the default branch |
| 278 | + ref: ${{ inputs.ref }} |
| 279 | + |
| 280 | + - name: Resolve parameters |
| 281 | + id: resolve_parameters |
| 282 | + run: | |
| 283 | + resolvedRef="${{ inputs.ref }}" |
| 284 | + if [ -z "$resolvedRef" ] |
| 285 | + then |
| 286 | + resolvedRef="${{ github.ref }}" |
| 287 | + fi |
| 288 | + echo "resolved_ref=$resolvedRef" >> $GITHUB_OUTPUT |
| 289 | + echo "INFO: Resolving short SHA for $resolvedRef" |
| 290 | + echo "short_sha=$(git rev-parse --short $resolvedRef)" >> $GITHUB_OUTPUT |
| 291 | + echo "INFO: Normalizing repository name (lowercase)" |
| 292 | + echo "repository_owner=$(echo ${{ github.repository_owner }} | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT |
| 293 | +
|
| 294 | + - name: Set up Helm |
| 295 | + uses: azure/setup-helm@1a275c3b69536ee54be43f2070a358922e12c8d4 |
| 296 | + with: |
| 297 | + version: ${{ env.HELM_VERSION }} |
| 298 | + |
| 299 | + - name: Publish new helm chart for gha-runner-scale-set-experimental |
| 300 | + run: | |
| 301 | + echo ${{ secrets.GITHUB_TOKEN }} | helm registry login ghcr.io --username ${{ github.actor }} --password-stdin |
| 302 | +
|
| 303 | + GHA_RUNNER_SCALE_SET_CHART_VERSION_TAG=$(cat charts/gha-runner-scale-set-experimental/Chart.yaml | grep version: | cut -d " " -d '"' -f 2) |
| 304 | + echo "GHA_RUNNER_SCALE_SET_CHART_VERSION_TAG=${GHA_RUNNER_SCALE_SET_CHART_VERSION_TAG}" >> $GITHUB_ENV |
| 305 | + helm package charts/gha-runner-scale-set-experimental/ --version="${GHA_RUNNER_SCALE_SET_CHART_VERSION_TAG}" |
| 306 | + helm push gha-runner-scale-set-experimental-"${GHA_RUNNER_SCALE_SET_CHART_VERSION_TAG}".tgz oci://ghcr.io/${{ steps.resolve_parameters.outputs.repository_owner }}/actions-runner-controller-charts |
| 307 | +
|
| 308 | + - name: Job summary |
| 309 | + run: | |
| 310 | + echo "New helm chart for gha-runner-scale-set-experimental published successfully!" >> $GITHUB_STEP_SUMMARY |
| 311 | + echo "" >> $GITHUB_STEP_SUMMARY |
| 312 | + echo "**Parameters:**" >> $GITHUB_STEP_SUMMARY |
| 313 | + echo "- Ref: ${{ steps.resolve_parameters.outputs.resolved_ref }}" >> $GITHUB_STEP_SUMMARY |
| 314 | + echo "- Short SHA: ${{ steps.resolve_parameters.outputs.short_sha }}" >> $GITHUB_STEP_SUMMARY |
| 315 | + echo "- gha-runner-scale-set-experimental Chart version: ${{ env.GHA_RUNNER_SCALE_SET_CHART_VERSION_TAG }}" >> $GITHUB_STEP_SUMMARY |
0 commit comments