fix azure release image naming

This commit is contained in:
Leonard Cohnen 2022-09-12 17:06:11 +02:00 committed by 3u13r
parent 2d8f2af91b
commit c1427123d9
2 changed files with 7 additions and 4 deletions

View File

@ -38,7 +38,7 @@ This checklist will prepare `v1.3.0` from `v1.2.0`. Adjust your version numbers
6. Update versions [versions.go](../../internal/versions/versions.go#L33-L39) to `v1.3.0` and **push your changes**.
7. Create a [production coreOS image](/.github/workflows/build-coreos.yml)
```sh
gh workflow run build-coreos.yml --ref release/v1.3 -F debug=false -F coreOSConfigBranch=release/v1.3
gh workflow run build-coreos.yml --ref release/v1.3 -F debug=false -F coreOSConfigBranch=release/v1.3 -F imageVersion=v1.3.0
```
8. Update [default images in config](/internal/config/images_enterprise.go)
9. Run E2E tests to confirm stability and [generate measurements](/.github/workflows/e2e-test-manual.yml)

View File

@ -6,6 +6,9 @@ on:
description: "Branch of CoreOS config repo to build from"
default: "main"
required: false
imageVersion:
description: "Semantic version including patch e.g. v<major>.<minor>.<patch> (only used for releases)"
required: false
debug:
description: "Build debug image"
type: boolean
@ -87,16 +90,16 @@ jobs:
run: |
timestamp=${{ steps.version.outputs.timestamp }}
semver=${{ steps.version.outputs.semanticVersion }}
releaseVersion=${{ steps.version.outputs.releaseVersion }}
imageVersion=${{ inputs.imageVersion }}
pseudover=${{ steps.version.outputs.pseudoVersion }}
echo "azureImageName=constellation-${pseudover//./-}" >> $GITHUB_ENV
if [ "${{ startsWith(github.ref, 'refs/heads/release/') && (inputs.debug == false) }}" = true ]
then
echo "gcpImageName=constellation-${releaseVersion//./-}" >> $GITHUB_ENV
echo "gcpImageName=constellation-${imageVersion//./-}" >> $GITHUB_ENV
echo "gcpImageFamily=constellation" >> $GITHUB_ENV
echo "azureGalleryName=Constellation" >> $GITHUB_ENV
echo "azureImageDefinition=constellation" >> $GITHUB_ENV
echo "azureImageVersion=${releaseVersion:1}" >> $GITHUB_ENV
echo "azureImageVersion=${imageVersion:1}" >> $GITHUB_ENV
elif [ "${{ ((github.ref == 'refs/heads/main') || startsWith(github.ref, 'refs/heads/release/')) && (inputs.debug == true) }}" = true ]
then
echo "gcpImageName=constellation-${{ steps.version.outputs.timestamp }}" >> $GITHUB_ENV