-
Notifications
You must be signed in to change notification settings - Fork 0
88 lines (77 loc) · 2.67 KB
/
test-e2e.yml
File metadata and controls
88 lines (77 loc) · 2.67 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
name: E2E Tests (Manual)
permissions:
contents: read
on:
workflow_dispatch:
inputs:
test_target:
description: 'Make target to run'
required: true
default: 'test-e2e-lifecycle'
type: choice
options:
- test-e2e-lifecycle
- test-e2e
- test-e2e-ha
- test-e2e-upgrade
- test-e2e-self-hosted
- test-e2e-md-remediation
- test-e2e-conformance
- test-e2e-conformance-fast
concurrency:
group: e2e-tests
cancel-in-progress: false
jobs:
test-e2e:
name: ${{ github.event.inputs.test_target }}
runs-on: ubuntu-latest
environment: e2e
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
fetch-depth: 0
persist-credentials: false
- name: Setup e2e environment
uses: ./.github/actions/e2e-setup
- name: Login to quay.io
if: >-
github.event.inputs.test_target == 'test-e2e-self-hosted' ||
github.event.inputs.test_target == 'test-e2e'
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0
with:
registry: quay.io
username: ${{ secrets.QUAY_E2E_USERNAME }}
password: ${{ secrets.QUAY_E2E_PASSWORD }}
- name: Run e2e tests
env:
CLOUDSCALE_API_TOKEN: ${{ secrets.CLOUDSCALE_API_TOKEN }}
TAG: e2e-manual-${{ github.sha }}
TEST_TARGET: ${{ github.event.inputs.test_target }}
run: make $TEST_TARGET
- name: Install regctl
if: >-
github.event.inputs.test_target == 'test-e2e-self-hosted' ||
github.event.inputs.test_target == 'test-e2e'
run: |
curl -sL https://github.com/regclient/regclient/releases/download/v0.11.2/regctl-linux-amd64 -o /usr/local/bin/regctl
chmod +x /usr/local/bin/regctl
- name: Clean up e2e image
if: >-
github.event.inputs.test_target == 'test-e2e-self-hosted' ||
github.event.inputs.test_target == 'test-e2e'
run: |
TAG="e2e-$(git rev-parse --short HEAD)"
regctl tag delete "quay.io/cloudscalech/capcs-staging:${TAG}" || true
- name: Redact secrets from artifacts
if: always()
env:
CLOUDSCALE_API_TOKEN: ${{ secrets.CLOUDSCALE_API_TOKEN }}
run: hack/log/redact.sh || true
- name: Upload test artifacts
if: always()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: e2e-artifacts-manual-${{ github.run_id }}
path: _artifacts/
retention-days: 14