Repository navigation
287 lines (281 loc) · 11.5 KB
/
Copy pathlinux.yml
File metadata and controls
287 lines (281 loc) · 11.5 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
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
name: Linux
on:
workflow_call:
inputs:
ubuntu:
required: true
type: boolean
almalinux:
required: true
type: boolean
alpine:
required: true
type: boolean
outputs:
jobs:
description: Job results
value: ${{ toJSON(jobs) }}
inputs:
description: Job selections
value: ${{ toJSON(inputs) }}
permissions:
contents: read
defaults:
run:
shell: sh
jobs:
ubuntu:
if: ${{ inputs.ubuntu }}
strategy:
fail-fast: false
matrix:
include:
- release: '26.04'
arch: amd64
machine: x86_64
runner: ubuntu-26.04
profiles: non-asan,self-peer,linux,no-userns
- release: '24.04'
arch: amd64
machine: x86_64
runner: ubuntu-24.04
profiles: non-asan,self-peer,linux,no-userns
- release: '22.04'
arch: amd64
machine: x86_64
runner: ubuntu-22.04
profiles: non-asan,self-peer,linux,no-zstd-threads
- release: '26.04'
arch: arm64
machine: aarch64
runner: ubuntu-26.04-arm
profiles: non-asan,self-peer,linux,no-simd,no-userns
- release: '24.04'
arch: arm64
machine: aarch64
runner: ubuntu-24.04-arm
profiles: non-asan,self-peer,linux,no-simd,no-userns
runs-on: ${{ matrix.runner }}
timeout-minutes: 45
name: Ubuntu ${{ matrix.release }} ${{ matrix.arch == 'amd64' && 'X86-64' || 'ARM64' }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
persist-credentials: false
- name: Platform
run: python3 -S .github/scripts/check-platform.py ubuntu --release "${{ matrix.release }}" --arch "${{ matrix.machine }}"
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install acl libacl1-dev attr libattr1-dev liblz4-dev libzstd-dev libxxhash-dev libidn2-dev python3-cmarkgfm openssl openssh-server
sudo install -d -o root -g root -m 0755 /run/sshd
sudo sysctl -w fs.protected_regular=2
echo "/usr/local/bin" >>"$GITHUB_PATH"
mkdir -p test-results
- name: Configure
run: ./configure --with-rrsync
- name: Build
id: build
run: make check-progs
- name: Installation check
run: python3 -S .github/scripts/installcheck.py
- name: Install
run: sudo make install
- name: Version
run: ./rsync --version
- name: Verify installed rsync-ssl
run: |
python3 -S testsuite/tools/check-rsync-ssl.py \
--rsync /usr/local/bin/rsync \
--rsync-ssl /usr/local/bin/rsync-ssl \
--openssl /usr/bin/openssl
- name: Verify restricted SSH
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: sudo python3 -S testsuite/tools/check-ssh.py --rsync /usr/local/bin/rsync --rrsync support/rrsync
- name: Install storage dependencies
if: ${{ !cancelled() && steps.build.outcome == 'success' && matrix.release == '24.04' && matrix.arch == 'amd64' }}
run: sudo apt-get install -y cryptsetup-bin e2fsprogs
- name: Storage
if: ${{ !cancelled() && steps.build.outcome == 'success' && matrix.release == '24.04' && matrix.arch == 'amd64' }}
run: sudo python3 -B -S testsuite/tools/check-storage.py --binary "$PWD/rsync" --output "$PWD/test-results/root/storage"
- name: Tests (root pipe)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: sudo python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" "pipe,root,${{ matrix.profiles }}" "$PWD/test-results/root/pipe" -j8
- name: Tests (root protocol 30)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: sudo python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" "pipe,root,${{ matrix.profiles }},protocol-30" "$PWD/test-results/root/protocol-30" --protocol=30 -j8
- name: Tests (root protocol 29)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: sudo python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" "pipe,root,${{ matrix.profiles }},protocol-29" "$PWD/test-results/root/protocol-29" --protocol=29 -j8
- name: Tests (root TCP)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: sudo python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" "root,${{ matrix.profiles }}" "$PWD/test-results/root/tcp" --use-tcp --daemon-tests-only -j8
- name: Tests (non-root pipe)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" "pipe,nonroot,${{ matrix.profiles }}" "$PWD/test-results/nonroot/pipe" -j8
- name: Tests (non-root TCP)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" "nonroot,${{ matrix.profiles }}" "$PWD/test-results/nonroot/tcp" --use-tcp --daemon-tests-only -j8
- name: Upload binaries
if: always()
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
retention-days: 45
name: ubuntu-${{ matrix.release }}-${{ matrix.arch }}-bin
if-no-files-found: error
path: |
rsync
rsync-ssl
rsync.1
rsync-ssl.1
rsyncd.conf.5
rrsync.1
rrsync
- name: Upload results
if: always()
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
retention-days: 45
name: ubuntu-${{ matrix.release }}-${{ matrix.arch }}-results
if-no-files-found: error
path: |
config.log
test-results/*/*/receipt.json
test-results/*/*/run.log
almalinux:
if: ${{ inputs.almalinux }}
runs-on: ubuntu-24.04
timeout-minutes: 45
container:
image: almalinux:8
name: AlmaLinux 8 X86-64
steps:
- name: Install Git
run: dnf -y install git
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
persist-credentials: false
- name: Install dependencies
run: |
# RHEL 8's default Python is too old for the test runner
dnf -y install epel-release
dnf config-manager --set-enabled powertools
dnf -y install gcc gcc-c++ make autoconf automake m4 \
python39 python39-pip diffutils \
openssl openssl-devel \
attr libattr-devel acl libacl-devel \
zstd libzstd-devel \
lz4 lz4-devel \
xxhash xxhash-devel \
libidn2 libidn2-devel
alternatives --set python3 /usr/bin/python3.9
pip3 install commonmark
- name: Platform
run: python3 -S .github/scripts/check-platform.py almalinux --release 8 --arch x86_64
- name: Configure
run: ./configure --with-rrsync
- name: Build
id: build
run: make check-progs
- name: Version
run: ./rsync --version
- name: Tests (root pipe)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" pipe,non-asan,root,self-peer,linux,no-zstd-threads,no-userns "$PWD/test-results/root/pipe" -j8
- name: Tests (root TCP)
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: python3 -S testsuite/tools/check.py "$PWD" "$PWD/rsync" non-asan,root,self-peer,linux,no-zstd-threads,no-userns "$PWD/test-results/root/tcp" --use-tcp --daemon-tests-only -j8
- name: Upload binaries
if: always()
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
retention-days: 45
name: almalinux-8-amd64-bin
if-no-files-found: error
path: |
rsync
rsync-ssl
rsync.1
rsync-ssl.1
rsyncd.conf.5
rrsync.1
rrsync
- name: Upload results
if: always()
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
retention-days: 45
name: almalinux-8-amd64-results
if-no-files-found: error
path: |
config.log
test-results/*/*/run.log
test-results/*/*/receipt.json
alpine:
if: ${{ inputs.alpine }}
runs-on: ubuntu-24.04
timeout-minutes: 45
name: Alpine 3.24.4 ${{ matrix.arch == 'amd64' && 'X86-64' || 'X86-32' }}
strategy:
fail-fast: false
matrix:
include:
- arch: amd64
platform: linux/amd64
apk_arch: x86_64
bits: 64
image: alpine@sha256:0f49f331d9212aff11b932863be4eb01cdf962969aa86dab7d1ee21ac6f5f52b
profiles: non-asan,self-peer,linux,no-simd,no-userns
- arch: x86
platform: linux/386
apk_arch: x86
bits: 32
image: alpine@sha256:55d68c85222dd92297b0f8885354739d89f0dc17fc2f903c49dc1d9c129c3d6a
profiles: non-asan,self-peer,linux,no-simd,no-userns
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
persist-credentials: false
- name: Prepare host
run: |
sudo sysctl -w fs.protected_regular=2
mkdir -p "$RUNNER_TEMP/rsync-alpine-${{ matrix.arch }}"
docker pull --platform "${{ matrix.platform }}" "${{ matrix.image }}"
- name: Run Alpine and collect results
env:
APK_ARCH: ${{ matrix.apk_arch }}
BITS: ${{ matrix.bits }}
PROFILES: ${{ matrix.profiles }}
run: |
docker run --rm -i --platform "${{ matrix.platform }}" \
-e APK_ARCH -e BITS -e PROFILES -e RSYNC_TEST_TMP=/dev/shm \
-v "$PWD:/source:ro" \
-v "$RUNNER_TEMP/rsync-alpine-${{ matrix.arch }}:/results" \
"${{ matrix.image }}" sh -ec '
apk add --no-cache acl acl-dev attr attr-dev autoconf automake bash build-base diffutils gawk git \
libidn2-dev linux-headers lz4-dev musl-locales openssl-dev py3-commonmark python3 setpriv xxhash-dev zstd-dev
exec python3 -S /source/.github/scripts/guest.py alpine --output /results
'
- name: Upload binaries
if: always()
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
retention-days: 45
name: alpine-3.24.4-${{ matrix.arch }}-bin
if-no-files-found: error
path: ${{ runner.temp }}/rsync-alpine-${{ matrix.arch }}/bin
- name: Upload results
if: always()
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
retention-days: 45
name: alpine-3.24.4-${{ matrix.arch }}-results
if-no-files-found: error
path: |
${{ runner.temp }}/rsync-alpine-${{ matrix.arch }}/config.log
${{ runner.temp }}/rsync-alpine-${{ matrix.arch }}/features.json
${{ runner.temp }}/rsync-alpine-${{ matrix.arch }}/*/*/receipt.json
${{ runner.temp }}/rsync-alpine-${{ matrix.arch }}/*/*/run.log