-
Notifications
You must be signed in to change notification settings - Fork 146
158 lines (147 loc) · 4.62 KB
/
Copy pathci.yml
File metadata and controls
158 lines (147 loc) · 4.62 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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
name: ci
on:
push:
branches:
- main
- podman-*
pull_request:
branches:
- main
- podman-*
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
path-filter:
runs-on: ubuntu-24.04
outputs:
all: ${{ steps.filter.outputs.all }}
storage: ${{ steps.filter.outputs.storage }}
image: ${{ steps.filter.outputs.image }}
common: ${{ steps.filter.outputs.common }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: dorny/paths-filter@7b450fff21473bca461d4b92ce414b9d0420d706 # v4.0.2
id: filter
with:
filters: .github/filters.yaml
validate:
uses: ./.github/workflows/validate.yml
storage-test:
needs: [path-filter, validate]
if: |
github.event_name != 'pull_request' ||
needs.path-filter.outputs.all == 'true' ||
needs.path-filter.outputs.storage == 'true'
name: "storage ${{ matrix.distro }} ${{ matrix.driver }}"
strategy:
fail-fast: false
matrix:
distro: [fedora-current, debian-sid]
driver: [vfs, overlay, overlay-transient, fuse-overlay, fuse-overlay-whiteout, btrfs]
exclude:
- distro: debian-sid
driver: overlay-transient
uses: ./.github/workflows/lima.yml
with:
runner: cncf-ubuntu-4-16-x86
module: storage
distro: ${{ matrix.distro }}
variant: ${{ matrix.driver }}
timeout: 20
storage-cross:
needs: [path-filter, validate]
if: |
github.event_name != 'pull_request' ||
needs.path-filter.outputs.all == 'true' ||
needs.path-filter.outputs.storage == 'true'
runs-on: ubuntu-24.04
timeout-minutes: 10
name: "Storage: Cross"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: stable
cache-dependency-path: "./storage/go.sum"
- name: Cross-compile
working-directory: ./storage
run: make cross
image-cross:
needs: [path-filter, validate]
if: |
github.event_name != 'pull_request' ||
needs.path-filter.outputs.all == 'true' ||
needs.path-filter.outputs.image == 'true'
runs-on: ubuntu-24.04
timeout-minutes: 10
name: "Image: Cross"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: stable
cache-dependency-path: "./image/go.sum"
- name: Install dependencies
run: |
sudo apt-get -qq update
sudo apt-get -qq install -y libgpgme-dev libassuan-dev libbtrfs-dev libdevmapper-dev
- name: Cross-compile
working-directory: ./image
run: make cross
image-test:
needs: [path-filter, validate]
if: |
github.event_name != 'pull_request' ||
needs.path-filter.outputs.all == 'true' ||
needs.path-filter.outputs.image == 'true'
name: "${{ matrix.module }} fedora-current ${{ matrix.variant }}"
strategy:
fail-fast: false
matrix:
variant: [default, openpgp, sequoia]
module: [image, image-skopeo]
uses: ./.github/workflows/lima.yml
with:
runner: cncf-ubuntu-4-16-x86
module: ${{ matrix.module }}
distro: fedora-current
variant: ${{ matrix.variant }}
timeout: 20
common-test:
needs: [path-filter, validate]
if: |
github.event_name != 'pull_request' ||
needs.path-filter.outputs.all == 'true' ||
needs.path-filter.outputs.common == 'true'
name: "common fedora-current"
uses: ./.github/workflows/lima.yml
with:
runner: cncf-ubuntu-4-16-x86
module: common
distro: fedora-current
timeout: 20
# N/B: GitHub merge protection is configured for this exact job name, DO NOT CHANGE IT.
success:
name: "Total Success"
if: always()
needs:
- path-filter
- validate
- storage-test
- storage-cross
- image-cross
- image-test
- common-test
runs-on: ubuntu-24.04
steps:
- name: Check all required jobs
run: |
if [[ "${{ contains(needs.*.result, 'failure') }}" == "true" ]] || \
[[ "${{ contains(needs.*.result, 'cancelled') }}" == "true" ]]; then
echo "One or more required jobs failed or were cancelled"
exit 1
fi
echo "All required jobs passed or were skipped"