ci: run e2e test manual on last release

Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
Paul Meyer 2023-03-21 09:18:14 +01:00
parent b33098346f
commit 24f974de66
2 changed files with 11 additions and 10 deletions

View File

@ -1,4 +1,4 @@
name: E2E meta test name: e2e meta test
description: "This test does the infrastructure management and runs the e2e test of your choice." description: "This test does the infrastructure management and runs the e2e test of your choice."
inputs: inputs:
@ -90,7 +90,7 @@ runs:
if: (!contains(fromJson('["sonobuoy full", "sonobuoy quick", "autoscaling", "perf-bench", "verify", "lb", "recover", "nop", "iamcreate"]'), inputs.test)) if: (!contains(fromJson('["sonobuoy full", "sonobuoy quick", "autoscaling", "perf-bench", "verify", "lb", "recover", "nop", "iamcreate"]'), inputs.test))
shell: bash shell: bash
run: | run: |
echo "Invalid input for test field: ${{ inputs.test }}" echo "::error::Invalid input for test field: ${{ inputs.test }}"
exit 1 exit 1
# Perf-bench's network benchmarks require at least two distinct worker nodes. # Perf-bench's network benchmarks require at least two distinct worker nodes.
@ -125,7 +125,7 @@ runs:
enterpriseCLI: ${{ inputs.keepMeasurements }} enterpriseCLI: ${{ inputs.keepMeasurements }}
outputPath: "build/constellation" outputPath: "build/constellation"
- name: Fetch CLI - name: Download CLI
if: inputs.cliVersion != '' if: inputs.cliVersion != ''
shell: bash shell: bash
run: | run: |

View File

@ -1,4 +1,4 @@
name: e2e Test Manual name: e2e test manual
on: on:
workflow_dispatch: workflow_dispatch:
@ -131,25 +131,25 @@ jobs:
run: | run: |
if [[ -z "${{ inputs.osImage }}" ]]; then if [[ -z "${{ inputs.osImage }}" ]]; then
echo "Using latest debug image from main." echo "Using latest debug image from main."
else
echo "Using image '${{ inputs.osImage }}'."
echo "image=${{ inputs.osImage }}" >> "$GITHUB_OUTPUT"
exit 0 exit 0
else
echo "image=${{ inputs.osImage }}" | tee -a "$GITHUB_OUTPUT"
fi fi
- name: Checkout head - name: Checkout head
if: inputs.git-ref == 'head' if: inputs.osImage == '' && inputs.git-ref == 'head'
uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0
with: with:
ref: ${{ !github.event.pull_request.head.repo.fork && github.head_ref || '' }} ref: ${{ !github.event.pull_request.head.repo.fork && github.head_ref || '' }}
- name: Checkout ref - name: Checkout ref
if: inputs.git-ref != 'head' if: inputs.osImage == '' && inputs.git-ref != 'head'
uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0
with: with:
ref: ${{ inputs.git-ref }} ref: ${{ inputs.git-ref }}
- name: Login to AWS - name: Login to AWS
if: inputs.osImage == ''
uses: aws-actions/configure-aws-credentials@e1e17a757e536f70e52b5a12b2e8d1d1c60e04ef # v2.0.0 uses: aws-actions/configure-aws-credentials@e1e17a757e536f70e52b5a12b2e8d1d1c60e04ef # v2.0.0
with: with:
role-to-assume: arn:aws:iam::795746500882:role/GithubConstellationVersionsAPIRead role-to-assume: arn:aws:iam::795746500882:role/GithubConstellationVersionsAPIRead
@ -157,7 +157,7 @@ jobs:
- name: Find latest image - name: Find latest image
id: find-latest-image id: find-latest-image
if: steps.check-input.outputs.image == '' if: inputs.osImage == ''
uses: ./.github/actions/versionsapi uses: ./.github/actions/versionsapi
with: with:
command: latest command: latest
@ -258,6 +258,7 @@ jobs:
azureUserAssignedIdentity: ${{ secrets.AZURE_E2E_USER_ASSIGNED_IDENTITY }} azureUserAssignedIdentity: ${{ secrets.AZURE_E2E_USER_ASSIGNED_IDENTITY }}
azureResourceGroup: ${{ steps.az_resource_group_gen.outputs.res_group_name }} azureResourceGroup: ${{ steps.az_resource_group_gen.outputs.res_group_name }}
osImage: ${{ needs.find-latest-image.outputs.image }} osImage: ${{ needs.find-latest-image.outputs.image }}
cliVersion: ${{ startsWith(needs.find-latest-image.outputs.image, 'v') && needs.find-latest-image.outputs.image || '' }}
isDebugImage: ${{ needs.find-latest-image.outputs.isDebugImage }} isDebugImage: ${{ needs.find-latest-image.outputs.isDebugImage }}
buildBuddyApiKey: ${{ secrets.BUILDBUDDY_ORG_API_KEY }} buildBuddyApiKey: ${{ secrets.BUILDBUDDY_ORG_API_KEY }}