From 584c3fed2fb1b42399624b0d918f2173e0694ec7 Mon Sep 17 00:00:00 2001 From: Adrian Stobbe Date: Tue, 2 Jan 2024 18:57:10 +0100 Subject: [PATCH] fixup! fixup! test devbuild --- .../workflows/e2e-test-provider-example.yml | 29 +++++-------------- 1 file changed, 7 insertions(+), 22 deletions(-) diff --git a/.github/workflows/e2e-test-provider-example.yml b/.github/workflows/e2e-test-provider-example.yml index 288722a8d94..04f90f160ab 100644 --- a/.github/workflows/e2e-test-provider-example.yml +++ b/.github/workflows/e2e-test-provider-example.yml @@ -118,14 +118,15 @@ jobs: nixTools: terraform - name: Build Constellation provider # CLI is needed for the upgrade assert and container push is needed for the microservice upgrade + working-directory: ${{ github.workspace }} shell: bash run: | mkdir build cd build bazel run //:devbuild --cli_edition=enterprise - - name: Remove local Terraform registry - if: inputs.providerVersion == '' + - name: Remove local Terraform registry # otherwise the local registry would be used instead of the public registry + if: inputs.providerVersion != '' shell: bash run: | bazel build //bazel/settings:tag @@ -287,28 +288,12 @@ jobs: terraform init terraform destroy -auto-approve - - name: Remove or add to local Terraform registry + - name: Build Constellation provider # add local registry if release version was used before + if: inputs.providerVersion != '' + working-directory: ${{ github.workspace }}/build shell: bash - id: upgrade_tf_provider run: | - bazel build //bazel/settings:tag - repository_root=$(git rev-parse --show-toplevel) - out_rel=$(bazel cquery --output=files //bazel/settings:tag) - build_version=$(cat "$(realpath "${repository_root}/${out_rel}")") - - terraform_provider_dir="${HOME}/.terraform.d/plugins/registry.terraform.io/edgelesssys/constellation/${build_version#v}/linux_amd64/" - - # remove local registry if it was used and public registry should be used now - if [[ "${{ inputs.providerVersion }}" == "" ]]; then - rm -rf "${terraform_provider_dir}" - fi - - # add to local registry if it was not used and local registry should be used now - if [[ "${{ inputs.providerVersion }}" != "" ]]; then - mkdir -p "${terraform_provider_dir}" - mv build/terraform-provider-constellation "${terraform_provider_dir}/terraform-provider-constellation_${build_version}" - fi - echo "build_version=${build_version}" | tee -a "$GITHUB_OUTPUT" + bazel run //:devbuild --cli_edition=enterprise - name: Update cluster configuration # for duplicate variable declaration, the last one is used working-directory: ${{ github.workspace }}/cluster