-
Notifications
You must be signed in to change notification settings - Fork 6
91 lines (81 loc) · 3.14 KB
/
flowzone.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
name: Flowzone
on:
pull_request:
types: [opened, synchronize, closed]
branches: [main, master]
# allow external contributions to use secrets within trusted code
# pull_request_target:
# types: [opened, synchronize, closed]
# branches: [main, master]
jobs:
flowzone:
name: Flowzone
uses: product-os/flowzone/.github/workflows/flowzone.yml@master
# prevent duplicate workflows and only allow one `pull_request` or `pull_request_target` for
# internal or external contributions respectively
if: |
(github.event.pull_request.head.repo.full_name == github.repository && github.event_name == 'pull_request') ||
(github.event.pull_request.head.repo.full_name != github.repository && github.event_name == 'pull_request_target')
secrets: inherit
e2e:
needs: [flowzone]
if: |
((github.event.pull_request.head.repo.full_name == github.repository && github.event_name == 'pull_request') ||
(github.event.pull_request.head.repo.full_name != github.repository && github.event_name == 'pull_request_target')) &&
github.event.action != 'closed'
runs-on: ubuntu-24.04
environment: ${{ matrix.ENVIRONMENT_URL }}
env:
SUITES: ./suites
REPORTS: ./reports
WORKSPACE: ./workspace
LEVIATHAN_ROOT: ./
BALENACLOUD_ORG: testbot
BALENACLOUD_APP_NAME: balena/testbot-rig
WORKER_TYPE: ${{ matrix.WORKER_TYPE }}
DEVICE_TYPE: ${{ matrix.DEVICE_TYPE }}
defaults:
run:
working-directory: .
shell: bash --noprofile --norc -eo pipefail -x {0}
strategy:
fail-fast: false
matrix:
include:
- DEVICE_TYPE: genericx86-64-ext
WORKER_TYPE: qemu
ENVIRONMENT_URL: balena-cloud.com
- DEVICE_TYPE: generic-amd64
WORKER_TYPE: qemu
ENVIRONMENT_URL: balena-cloud.com
- DEVICE_TYPE: generic-aarch64
WORKER_TYPE: qemu
ENVIRONMENT_URL: bm.balena-dev.com
- DEVICE_TYPE: raspberrypi3
WORKER_TYPE: testbot
ENVIRONMENT_URL: bm.balena-dev.com
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
submodules: true
persistent-credentials: false
- name: Copy suite config
run: cp -a ${{ env.SUITES }}/config.js ${{ env.WORKSPACE }}/config.js
- name: Leviathan build + test
uses: ./
env:
BALENACLOUD_API_KEY: ${{ secrets.BALENA_API_TEST_KEY }}
BALENACLOUD_API_URL: ${{ vars.BALENA_HOST || matrix.ENVIRONMENT_URL }}
BALENACLOUD_SSH_PORT: ${{ vars.BALENACLOUD_SSH_PORT }}
BALENACLOUD_SSH_URL: ${{ vars.BALENACLOUD_SSH_URL }}
DEVICE_TYPE: ${{ matrix.DEVICE_TYPE }}
WORKER_TYPE: ${{ matrix.WORKER_TYPE }}
QEMU_CPUS: 1
QEMU_MEMORY: "1G"
TEST_SUITE: e2e
BALENACLOUD_APP_NAME: ${{ env.BALENACLOUD_APP_NAME }}
BALENACLOUD_ORG: ${{ env.BALENACLOUD_ORG }}
LEVIATHAN_ROOT: ${{ env.LEVIATHAN_ROOT }}
REPORTS: ${{ env.REPORTS }}
SUITES: ${{ env.SUITES }}
WORKSPACE: ${{ env.WORKSPACE }}