-
Notifications
You must be signed in to change notification settings - Fork 7
92 lines (77 loc) · 2.97 KB
/
e2e-testing.yml
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
89
90
91
92
name: e2e-testing
run-name: Create all entities in Seqera Platform from end-to-end with seqerakit
# This workflow can be triggered manually with GitHub actions workflow dispatch button.
# It will automate the end-to-end creation all of the following entities in Seqera Platform.
on:
pull_request_target:
branches: [main]
workflow_dispatch:
inputs:
pre_delete:
description: 'Delete all entities in the yaml before testing'
required: false
type: boolean
default: false
clearup:
description: 'Clearup all entities in yaml after testing'
required: false
type: boolean
default: true
jobs:
e2e-testing:
name:
if: github.repository == 'seqeralabs/seqera-kit'
runs-on: ubuntu-latest
env:
TOWER_ACCESS_TOKEN: ${{ secrets.TOWER_ACCESS_TOKEN }}
TOWER_GITHUB_PASSWORD: ${{ secrets.TOWER_GITHUB_PASSWORD }}
DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_PASSWORD }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_ASSUME_ROLE_ARN: ${{ secrets.AWS_ASSUME_ROLE_ARN }}
AZURE_BATCH_KEY: ${{ secrets.AZURE_BATCH_KEY }}
AZURE_STORAGE_KEY: ${{ secrets.AZURE_STORAGE_KEY }}
GOOGLE_KEY: ${{ secrets.GOOGLE_KEY }}
SENTIEON_LICENSE_BASE64: ${{ secrets.SENTIEON_LICENSE_BASE64 }}
steps:
- name: Check out source-code repository
uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: '3.12'
- name: Install pip & seqerakit
run: |
pip install -e .
- name: Install Tower CLI v0.9.1
run: |
wget https://github.com/seqeralabs/tower-cli/releases/download/v0.9.1/tw-linux-x86_64 \
&& chmod +x tw-linux-x86_64 \
&& sudo mv tw-linux-x86_64 /usr/local/bin/tw
- name: pre-clear
# Note this task always 'succeeds'
if: ( success() || failure() ) && ( github.event_name != 'workflow_dispatch' || inputs.pre_delete )
run: |
temp_file=$(mktemp -q)
echo $GOOGLE_KEY | base64 -d > $temp_file
export GOOGLE_KEY=$temp_file
seqerakit examples/yaml/e2e/*.yml --delete || true
- name: dryrun
run: |
temp_file=$(mktemp -q)
echo $GOOGLE_KEY | base64 -d > $temp_file
export GOOGLE_KEY=$temp_file
seqerakit examples/yaml/e2e/*.yml --dryrun
- name: create
run: |
temp_file=$(mktemp -q)
echo $GOOGLE_KEY | base64 -d > $temp_file
export GOOGLE_KEY=$temp_file
seqerakit examples/yaml/e2e/*.yml
- name: teardown
if: ( success() || failure() ) && ( github.event_name != 'workflow_dispatch' || inputs.clearup )
run: |
temp_file=$(mktemp -q)
echo $GOOGLE_KEY | base64 -d > $temp_file
export GOOGLE_KEY=$temp_file
seqerakit examples/yaml/e2e/*.yml --delete