CHANGELOG for 1.5.5 #108
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Create and Publish Helm Packages | |
on: | |
push: | |
tags: | |
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10, will be triggered when a new tag is pushed | |
jobs: | |
call-ci-servicex: | |
uses: ./.github/workflows/ci_servicex.yaml | |
secrets: inherit | |
call-ci-helm-tests: | |
uses: ./.github/workflows/ci_helm_tests.yaml | |
secrets: inherit | |
build: | |
name: Create Release | |
needs: [call-ci-servicex, call-ci-helm-tests] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4.2.2 | |
- name: Pull flux_river_configs | |
uses: actions/checkout@v4.2.2 | |
with: | |
repository: ssl-hep/flux_river_configs | |
ref: main | |
path: flux_river_configs | |
token: ${{ secrets.API_TOKEN_GITHUB }} | |
- name: Pull ssl-helm-charts | |
uses: actions/checkout@v4.2.2 | |
with: | |
repository: ssl-hep/ssl-helm-charts | |
ref: gh-pages | |
path: ssl-helm-charts | |
token: ${{ secrets.API_TOKEN_GITHUB }} | |
- name: Create release version env var | |
run: | | |
# Remove leading v from version string | |
echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" | sed s/v// >> $GITHUB_ENV | |
echo "$RELEASE_VERSION" | |
echo "DOCKER_TAG=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV | |
echo "$DOCKER_TAG" | |
- name: Set version in helm values.yaml | |
# Update the tags for images in the helm Chart.yaml and values.yaml to match | |
# The deployed docker image tag | |
uses: mikefarah/yq@v4.45.1 | |
with: | |
cmd: | | |
# Update the version of the helm chart | |
yq -i '.appVersion = strenv(RELEASE_VERSION) | .appVersion style="double" | .version = "'$RELEASE_VERSION'"| .version style="double" ' helm/servicex/Chart.yaml && | |
# Update the tags for the well known images in the helm values.yaml | |
yq -i '.app.tag = strenv(DOCKER_TAG) | .app.tag style="double" | | |
.transformer.sidecarTag = strenv(DOCKER_TAG) | .transformer.sidecarTag style="double" | | |
.minioCleanup.tag = strenv(DOCKER_TAG) | .minioCleanup.tag style="double" | | |
.x509Secrets.tag = strenv(DOCKER_TAG) | .x509Secrets.tag style="double" ' helm/servicex/values.yaml && | |
# Loop over each of the DID Finders to update the tags for each | |
DIDFINDERS=$(yq '.didFinder | keys | .[]' helm/servicex/values.yaml) && | |
for i in $DIDFINDERS; do yq -i '.didFinder.[$i].tag=strenv(DOCKER_TAG) | .didFinder.[$i].tag style="double"' helm/servicex/values.yaml; done && | |
# Loop over each of the Codegens to update the tags for each | |
CODEGENS=$(yq '.codeGen | keys | .[]' helm/servicex/values.yaml) && | |
for i in $CODEGENS; do yq -i '.codeGen.[$i].tag=strenv(DOCKER_TAG) | .codeGen.[$i].tag style="double"' helm/servicex/values.yaml; done | |
- name: Set up Helm | |
uses: azure/setup-helm@v4 | |
with: | |
version: v3.9.2 | |
- name: Create helm package | |
working-directory: ./helm | |
run: | | |
helm dependency update servicex | |
helm package servicex | |
mv servicex-$RELEASE_VERSION.tgz ../ssl-helm-charts | |
helm repo index ../ssl-helm-charts --url https://ssl-hep.github.io/ssl-helm-charts/ | |
- name: Pushes to ssl-helm-packages repository | |
uses: cpina/github-action-push-to-another-repository@v1.7.2 | |
env: | |
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} | |
with: | |
source-directory: 'ssl-helm-charts' | |
destination-github-username: 'ssl-hep' | |
destination-repository-name: 'ssl-helm-charts' | |
target-branch: 'gh-pages' | |
user-email: 'bengal1@illinois.edu' | |
- name: Set version in flux_river_config for the production environment | |
uses: mikefarah/yq@v4.45.1 | |
with: | |
cmd: | | |
# Update the chart version to pick up | |
yq -i '.spec.chart.spec.version = strenv(RELEASE_VERSION) | .spec.chart.spec.version style="double" ' flux_river_configs/servicex-prod/values.yaml | |
- name: Pushes to flux-river-configs repository | |
uses: cpina/github-action-push-to-another-repository@v1.7.2 | |
env: | |
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} | |
with: | |
source-directory: 'flux_river_configs' | |
destination-github-username: 'ssl-hep' | |
destination-repository-name: 'flux_river_configs' | |
target-branch: 'main' | |
user-email: 'bengal1@illinois.edu' | |
- name: Create Release | |
id: create_release | |
uses: softprops/action-gh-release@v2.2.1 | |
with: | |
tag_name: ${{ github.ref }} | |
token: ${{ secrets.GITHUB_TOKEN }} | |
name: Release ${{ github.ref }} | |
draft: false | |
prerelease: false |