-
Notifications
You must be signed in to change notification settings - Fork 890
67 lines (66 loc) · 2.34 KB
/
ci-schedule.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
name: CI Schedule Workflow
on:
schedule:
# Run this workflow "At 18:00 UTC on Sunday and Saturday"
- cron: '0 18 * * 0,6'
jobs:
e2e:
name: e2e test
# prevent job running from forked repository
if: ${{ github.repository == 'karmada-io/karmada' }}
runs-on: ubuntu-22.04
strategy:
# max-parallel limits the max number of jobs running at the same time.
# We set it to 5 to avoid too many jobs running at the same time, causing the CI to fail because of resource limitations.
max-parallel: 5
fail-fast: false
matrix:
k8s: [ v1.23.4, v1.24.2, v1.25.0, v1.26.0, v1.27.3, v1.28.0, v1.29.0 ]
steps:
# Free up disk space on Ubuntu
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
with:
# this might remove tools that are actually needed, if set to "true" but frees about 6 GB
tool-cache: false
# all of these default to true, but feel free to set to "false" if necessary for your workflow
android: true
dotnet: true
haskell: true
large-packages: false
docker-images: false
swap-storage: false
- name: checkout code
uses: actions/checkout@v4
with:
# Number of commits to fetch. 0 indicates all history for all branches and tags.
# We need to guess version via git tags.
fetch-depth: 0
- name: install Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
- name: setup e2e test environment
uses: nick-fields/[email protected]
with:
max_attempts: 3
timeout_minutes: 20
command: |
export CLUSTER_VERSION=kindest/node:${{ matrix.k8s }}
hack/local-up-karmada.sh
- name: run e2e
run: |
export ARTIFACTS_PATH=${{ github.workspace }}/karmada-e2e-logs/${{ matrix.k8s }}/
hack/run-e2e.sh
- name: upload logs
if: always()
uses: actions/upload-artifact@v4
with:
name: karmada_e2e_log_${{ matrix.k8s }}
path: ${{ github.workspace }}/karmada-e2e-logs/${{ matrix.k8s }}/
- name: upload kind logs
if: always()
uses: actions/upload-artifact@v4
with:
name: karmada_kind_log_${{ matrix.k8s }}
path: /tmp/karmada/