mirror of
https://github.com/edgelesssys/constellation.git
synced 2024-10-01 01:36:09 -04:00
67 lines
2.1 KiB
YAML
67 lines
2.1 KiB
YAML
name: E2E QEMU test
|
|
description: "Test MiniConstellation functionality on Azure VM."
|
|
|
|
inputs:
|
|
azureClientID:
|
|
description: "Azure client to use for login with OIDC"
|
|
required: true
|
|
azureSubscriptionID:
|
|
description: "Azure subscription to use for login with OIDC"
|
|
required: true
|
|
azureTenantID:
|
|
description: "Azure tenant to use for login with OIDC"
|
|
required: true
|
|
azureIAMCredentials:
|
|
description: "Azure IAM credentials used for cleaning up resources"
|
|
required: true
|
|
registry:
|
|
description: "Container registry to use"
|
|
required: true
|
|
githubToken:
|
|
description: "GitHub authorization token"
|
|
required: true
|
|
|
|
runs:
|
|
using: "composite"
|
|
steps:
|
|
- name: Install terraform
|
|
uses: hashicorp/setup-terraform@651471c36a6092792c552e8b1bef71e592b462d8 # v3.1.1
|
|
with:
|
|
terraform_wrapper: false
|
|
|
|
- name: Setup bazel
|
|
uses: ./.github/actions/setup_bazel_nix
|
|
|
|
- name: Log in to the Container registry
|
|
uses: ./.github/actions/container_registry_login
|
|
with:
|
|
registry: ${{ inputs.registry }}
|
|
username: ${{ github.actor }}
|
|
password: ${{ inputs.githubToken }}
|
|
|
|
- name: MiniConstellation E2E
|
|
shell: bash
|
|
id: e2e-test
|
|
env:
|
|
ARM_CLIENT_ID: ${{ inputs.azureClientID }}
|
|
ARM_SUBSCRIPTION_ID: ${{ inputs.azureSubscriptionID }}
|
|
ARM_TENANT_ID: ${{ inputs.azureTenantID }}
|
|
run: |
|
|
bazel run --test_timeout=14400 //e2e/miniconstellation:push_remote_test
|
|
|
|
- name: Log in to azure
|
|
# only log in if e2e test failed or if the run was cancelled
|
|
if: (failure() && steps.e2e-test.conclusion == 'failure') || cancelled()
|
|
uses: ./.github/actions/login_azure
|
|
with:
|
|
azure_credentials: ${{ inputs.azureIAMCredentials }}
|
|
|
|
- name: Clean up after failure
|
|
shell: bash
|
|
# clean up if e2e test failed or if the run was cancelled
|
|
if: (failure() && steps.e2e-test.conclusion == 'failure') || cancelled()
|
|
run: |
|
|
rg_name=${{ steps.e2e-test.outputs.rgname }}
|
|
echo "[*] Deleting resource group $rg_name"
|
|
az group delete -y --resource-group "$rg_name"
|