2
2
3
3
on :
4
4
pull_request :
5
- types : [ ' labeled', ' unlabeled', ' opened', ' synchronize', ' reopened' ]
5
+ types : [" labeled", " unlabeled", " opened", " synchronize", " reopened" ]
6
6
merge_group :
7
7
push :
8
8
branches :
24
24
tests :
25
25
name : CI Test Suite
26
26
if : " github.event_name != 'pull_request' || ! contains(github.event.pull_request.labels.*.name, 'flaky-test')"
27
- uses : ' ./.github/workflows/tests.yaml'
27
+ uses : " ./.github/workflows/tests.yaml"
28
28
29
29
cross_build :
30
30
name : Cross Build Only
35
35
fail-fast : false
36
36
matrix :
37
37
target :
38
- # cross tests are currently broken vor armv7 and aarch64
39
- # see https://github.com/cross-rs/cross/issues/1311
38
+ # cross tests are currently broken vor armv7 and aarch64
39
+ # see https://github.com/cross-rs/cross/issues/1311
40
40
# - armv7-linux-androideabi
41
41
# - aarch64-linux-android
42
42
# Freebsd execution fails in cross
@@ -45,29 +45,29 @@ jobs:
45
45
# Netbsd execution fails to link in cross
46
46
# - x86_64-unknown-netbsd
47
47
steps :
48
- - name : Checkout
49
- uses : actions/checkout@v4
50
- with :
51
- submodules : recursive
52
-
53
- - name : Install rust stable
54
- uses : dtolnay/rust-toolchain@stable
55
-
56
- - name : Cleanup Docker
57
- continue-on-error : true
58
- run : |
59
- docker kill $(docker ps -q)
60
-
61
- # See https://github.com/cross-rs/cross/issues/1222
62
- - uses : taiki-e/install-action@cross
63
-
64
- - name : build
65
- # cross tests are currently broken vor armv7 and aarch64
66
- # see https://github.com/cross-rs/cross/issues/1311. So on
67
- # those platforms we only build but do not run tests.
68
- run : cross build --all --target ${{ matrix.target }}
69
- env :
70
- RUST_LOG : ${{ runner.debug && 'TRACE' || 'DEBUG'}}
48
+ - name : Checkout
49
+ uses : actions/checkout@v4
50
+ with :
51
+ submodules : recursive
52
+
53
+ - name : Install rust stable
54
+ uses : dtolnay/rust-toolchain@stable
55
+
56
+ - name : Cleanup Docker
57
+ continue-on-error : true
58
+ run : |
59
+ docker kill $(docker ps -q)
60
+
61
+ # See https://github.com/cross-rs/cross/issues/1222
62
+ - uses : taiki-e/install-action@cross
63
+
64
+ - name : build
65
+ # cross tests are currently broken vor armv7 and aarch64
66
+ # see https://github.com/cross-rs/cross/issues/1311. So on
67
+ # those platforms we only build but do not run tests.
68
+ run : cross build --all --target ${{ matrix.target }}
69
+ env :
70
+ RUST_LOG : ${{ runner.debug && 'TRACE' || 'DEBUG'}}
71
71
72
72
android_build :
73
73
name : Android Build Only
@@ -82,38 +82,38 @@ jobs:
82
82
- aarch64-linux-android
83
83
- armv7-linux-androideabi
84
84
steps :
85
- - name : Checkout
86
- uses : actions/checkout@v4
87
-
88
- - name : Set up Rust
89
- uses : dtolnay/rust-toolchain@stable
90
- with :
91
- target : ${{ matrix.target }}
92
- - name : Install rustup target
93
- run : rustup target add ${{ matrix.target }}
94
-
95
- - name : Setup Java
96
- uses : actions/setup-java@v4
97
- with :
98
- distribution : ' temurin'
99
- java-version : ' 17 '
100
-
101
- - name : Setup Android SDK
102
- uses : android-actions/setup-android@v3
103
-
104
- - name : Setup Android NDK
105
- uses : arqu/setup-ndk@main
106
- id : setup-ndk
107
- with :
108
- ndk-version : r23
109
- add-to-path : true
110
-
111
- - name : Build
112
- env :
113
- ANDROID_NDK_HOME : ${{ steps.setup-ndk.outputs.ndk-path }}
114
- run : |
115
- cargo install --version 3.5.4 cargo-ndk
116
- cargo ndk --target ${{ matrix.target }} build
85
+ - name : Checkout
86
+ uses : actions/checkout@v4
87
+
88
+ - name : Set up Rust
89
+ uses : dtolnay/rust-toolchain@stable
90
+ with :
91
+ target : ${{ matrix.target }}
92
+ - name : Install rustup target
93
+ run : rustup target add ${{ matrix.target }}
94
+
95
+ - name : Setup Java
96
+ uses : actions/setup-java@v4
97
+ with :
98
+ distribution : " temurin"
99
+ java-version : " 17 "
100
+
101
+ - name : Setup Android SDK
102
+ uses : android-actions/setup-android@v3
103
+
104
+ - name : Setup Android NDK
105
+ uses : arqu/setup-ndk@main
106
+ id : setup-ndk
107
+ with :
108
+ ndk-version : r23
109
+ add-to-path : true
110
+
111
+ - name : Build
112
+ env :
113
+ ANDROID_NDK_HOME : ${{ steps.setup-ndk.outputs.ndk-path }}
114
+ run : |
115
+ cargo install --version 3.5.4 cargo-ndk
116
+ cargo ndk --target ${{ matrix.target }} build
117
117
118
118
cross_test :
119
119
name : Cross Test
@@ -126,27 +126,26 @@ jobs:
126
126
target :
127
127
- i686-unknown-linux-gnu
128
128
steps :
129
- - name : Checkout
130
- uses : actions/checkout@v4
131
- with :
132
- submodules : recursive
133
-
134
- - name : Install rust stable
135
- uses : dtolnay/rust-toolchain@stable
129
+ - name : Checkout
130
+ uses : actions/checkout@v4
131
+ with :
132
+ submodules : recursive
136
133
137
- - name : Cleanup Docker
138
- continue-on-error : true
139
- run : |
140
- docker kill $(docker ps -q)
134
+ - name : Install rust stable
135
+ uses : dtolnay/rust-toolchain@stable
141
136
142
- # See https://github.com/cross-rs/cross/issues/1222
143
- - uses : taiki-e/install-action@cross
137
+ - name : Cleanup Docker
138
+ continue-on-error : true
139
+ run : |
140
+ docker kill $(docker ps -q)
144
141
145
- - name : test
146
- run : cross test --all --target ${{ matrix.target }} -- --test-threads=12
147
- env :
148
- RUST_LOG : ${{ runner.debug && 'TRACE' || 'DEBUG' }}
142
+ # See https://github.com/cross-rs/cross/issues/1222
143
+ - uses : taiki-e/install-action@cross
149
144
145
+ - name : test
146
+ run : cross test --all --target ${{ matrix.target }} -- --test-threads=12
147
+ env :
148
+ RUST_LOG : ${{ runner.debug && 'TRACE' || 'DEBUG' }}
150
149
151
150
wasm_build :
152
151
name : Build wasm32
@@ -190,7 +189,7 @@ jobs:
190
189
# uses: obi1kenobi/cargo-semver-checks-action@v2
191
190
uses : n0-computer/cargo-semver-checks-action@feat-baseline
192
191
with :
193
- package : iroh, iroh-base, iroh-cli, iroh- dns-server, iroh-metrics, iroh-net, iroh-net-bench, iroh-node-util, iroh-router, netwatch, portmapper, iroh-relay, iroh-net-report
192
+ package : iroh, iroh-base, iroh-dns-server, iroh-metrics, iroh-net, iroh-net-bench, iroh-node-util, iroh-router, netwatch, portmapper, iroh-relay, iroh-net-report
194
193
baseline-rev : ${{ env.HEAD_COMMIT_SHA }}
195
194
use-cache : false
196
195
@@ -202,13 +201,13 @@ jobs:
202
201
RUSTC_WRAPPER : " sccache"
203
202
SCCACHE_GHA_ENABLED : " on"
204
203
steps :
205
- - uses : actions/checkout@v4
206
- - uses : dtolnay/rust-toolchain@stable
207
- with :
208
- components : rustfmt
209
- -
uses :
mozilla-actions/[email protected]
210
- - uses : taiki-e/install-action@cargo-make
211
- - run : cargo make format-check
204
+ - uses : actions/checkout@v4
205
+ - uses : dtolnay/rust-toolchain@stable
206
+ with :
207
+ components : rustfmt
208
+ -
uses :
mozilla-actions/[email protected]
209
+ - uses : taiki-e/install-action@cargo-make
210
+ - run : cargo make format-check
212
211
213
212
check_docs :
214
213
timeout-minutes : 30
@@ -218,17 +217,17 @@ jobs:
218
217
RUSTC_WRAPPER : " sccache"
219
218
SCCACHE_GHA_ENABLED : " on"
220
219
steps :
221
- - uses : actions/checkout@v4
222
- - uses : dtolnay/rust-toolchain@master
223
- with :
224
- toolchain : nightly-2024-05-02
225
- - name : Install sccache
226
- uses :
mozilla-actions/[email protected]
227
-
228
- - name : Docs
229
- run : cargo doc --workspace --all-features --no-deps --document-private-items
230
- env :
231
- RUSTDOCFLAGS : --cfg docsrs
220
+ - uses : actions/checkout@v4
221
+ - uses : dtolnay/rust-toolchain@master
222
+ with :
223
+ toolchain : nightly-2024-05-02
224
+ - name : Install sccache
225
+ uses :
mozilla-actions/[email protected]
226
+
227
+ - name : Docs
228
+ run : cargo doc --workspace --all-features --no-deps --document-private-items
229
+ env :
230
+ RUSTDOCFLAGS : --cfg docsrs
232
231
233
232
clippy_check :
234
233
timeout-minutes : 30
@@ -237,23 +236,23 @@ jobs:
237
236
RUSTC_WRAPPER : " sccache"
238
237
SCCACHE_GHA_ENABLED : " on"
239
238
steps :
240
- - uses : actions/checkout@v4
241
- - uses : dtolnay/rust-toolchain@stable
242
- with :
243
- components : clippy
244
- - name : Install sccache
245
- uses :
mozilla-actions/[email protected]
239
+ - uses : actions/checkout@v4
240
+ - uses : dtolnay/rust-toolchain@stable
241
+ with :
242
+ components : clippy
243
+ - name : Install sccache
244
+ uses :
mozilla-actions/[email protected]
246
245
247
- # TODO: We have a bunch of platform-dependent code so should
248
- # probably run this job on the full platform matrix
249
- - name : clippy check (all features)
250
- run : cargo clippy --workspace --all-features --all-targets --bins --tests --benches
246
+ # TODO: We have a bunch of platform-dependent code so should
247
+ # probably run this job on the full platform matrix
248
+ - name : clippy check (all features)
249
+ run : cargo clippy --workspace --all-features --all-targets --lib -- bins --tests --benches --examples
251
250
252
- - name : clippy check (no features)
253
- run : cargo clippy --workspace --no-default-features --lib --bins --tests
251
+ - name : clippy check (no features)
252
+ run : cargo clippy --workspace --no-default-features --all-targets -- lib --bins --tests --benches --examples
254
253
255
- - name : clippy check (default features)
256
- run : cargo clippy --workspace --all-targets
254
+ - name : clippy check (default features)
255
+ run : cargo clippy --workspace --all-targets --lib --bins --tests --benches --examples
257
256
258
257
msrv :
259
258
if : " github.event_name != 'pull_request' || ! contains(github.event.pull_request.labels.*.name, 'flaky-test')"
@@ -264,16 +263,16 @@ jobs:
264
263
RUSTC_WRAPPER : " sccache"
265
264
SCCACHE_GHA_ENABLED : " on"
266
265
steps :
267
- - uses : actions/checkout@v4
268
- - uses : dtolnay/rust-toolchain@master
269
- with :
270
- toolchain : ${{ env.MSRV }}
271
- - name : Install sccache
272
- uses :
mozilla-actions/[email protected]
266
+ - uses : actions/checkout@v4
267
+ - uses : dtolnay/rust-toolchain@master
268
+ with :
269
+ toolchain : ${{ env.MSRV }}
270
+ - name : Install sccache
271
+ uses :
mozilla-actions/[email protected]
273
272
274
- - name : Check MSRV all features
275
- run : |
276
- cargo +$MSRV check --workspace --all-targets
273
+ - name : Check MSRV all features
274
+ run : |
275
+ cargo +$MSRV check --workspace --all-targets
277
276
278
277
cargo_deny :
279
278
timeout-minutes : 30
@@ -290,73 +289,19 @@ jobs:
290
289
netsim-integration-tests :
291
290
permissions : write-all
292
291
if : " github.event_name != 'pull_request' || ! contains(github.event.pull_request.labels.*.name, 'flaky-test')"
293
- uses : ' ./.github/workflows/netsim_runner.yaml'
292
+ uses : " ./.github/workflows/netsim_runner.yaml"
294
293
secrets : inherit
295
294
with :
296
295
branch : ${{ github.ref }}
297
296
max_workers : 4
298
297
netsim_branch : " main"
299
- sim_paths : " sims/iroh /iroh.json,sims/integration "
298
+ sim_paths : " sims/iroh_v2 /iroh.json,sims/integration_v2 "
300
299
pr_number : ${{ github.event.pull_request.number || '' }}
301
300
302
- docker_build_and_test :
303
- name : Docker Test
304
- if : " github.event_name != 'pull_request' || ! contains(github.event.pull_request.labels.*.name, 'flaky-test')"
305
- timeout-minutes : 30
306
- runs-on : [self-hosted, linux, X64]
307
- steps :
308
- - name : Checkout
309
- uses : actions/checkout@v4
310
-
311
- - name : Install rust
312
- uses : dtolnay/rust-toolchain@master
313
- with :
314
- toolchain : stable
315
-
316
- - name : Install sccache
317
- uses :
mozilla-actions/[email protected]
318
-
319
- - name : Prep
320
- run : sudo apt-get install musl-tools -y
321
-
322
- - name : Build iroh
323
- run : cargo build --profile=dev-ci --all-features --bin iroh --target x86_64-unknown-linux-musl
324
-
325
- - name : Prep bins
326
- run : |
327
- mkdir -p bins/linux/amd64
328
- cp target/x86_64-unknown-linux-musl/dev-ci/iroh bins/linux/amd64/iroh
329
-
330
- - name : Cleanup Docker
331
- continue-on-error : true
332
- run : |
333
- docker kill $(docker ps -q)
334
-
335
- - name : Set up Docker Buildx
336
- uses : docker/setup-buildx-action@v3
337
-
338
- - name : Build Docker image
339
- uses : docker/build-push-action@v6
340
- with :
341
- context : .
342
- push : false
343
- load : true
344
- tags : n0computer/iroh-test:latest
345
- target : iroh
346
- platforms : linux/amd64
347
- file : docker/Dockerfile.ci
348
-
349
- - name : Run Docker image & stats test
350
- run : |
351
- docker run -p 9090:9090 -p 4919:4919/udp -Pd n0computer/iroh-test:latest --rpc-addr 0.0.0.0:4919 start
352
- # Give the server time to start
353
- sleep 3
354
- target/x86_64-unknown-linux-musl/dev-ci/iroh --rpc-addr 127.0.0.1:4919 stats
355
-
356
301
codespell :
357
302
timeout-minutes : 30
358
303
runs-on : ubuntu-latest
359
304
steps :
360
- - uses : actions/checkout@v4
361
- - run : pip install --user codespell[toml]
362
- - run : codespell --ignore-words-list=ans,atmost,crate,inout,ratatui,ser,stayin,swarmin,worl --skip=CHANGELOG.md
305
+ - uses : actions/checkout@v4
306
+ - run : pip install --user codespell[toml]
307
+ - run : codespell --ignore-words-list=ans,atmost,crate,inout,ratatui,ser,stayin,swarmin,worl --skip=CHANGELOG.md
0 commit comments