-
Notifications
You must be signed in to change notification settings - Fork 19
189 lines (168 loc) · 6.61 KB
/
daily.yaml
File metadata and controls
189 lines (168 loc) · 6.61 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
# Daily CI jobs that don't need to run on every PR
# These jobs run on a schedule and report failures to Discord
name: Daily CI
on:
schedule:
# 06:00 UTC every day
- cron: "0 6 * * *"
workflow_dispatch:
concurrency:
group: daily-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
RUST_BACKTRACE: 1
RUSTFLAGS: -Dwarnings
jobs:
proptests:
name: Extended Proptest Run
timeout-minutes: 20
runs-on: [self-hosted, linux, X64]
env:
RUSTC_WRAPPER: "sccache"
steps:
- uses: actions/checkout@v6
- uses: dtolnay/rust-toolchain@stable
- name: Install cargo-nextest
uses: taiki-e/install-action@v2
with:
tool: nextest@0.9.80
- uses: taiki-e/install-action@cargo-make
- name: Install sccache
uses: mozilla-actions/sccache-action@v0.0.9
- name: Run proptests (10 minutes)
run: cargo make proptests-long
test-freebsd:
# see https://github.com/actions/runner/issues/385
# use https://github.com/vmactions/freebsd-vm for now
timeout-minutes: 45
name: test on freebsd
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: test on freebsd
uses: vmactions/freebsd-vm@v1
with:
usesh: true
mem: 4096
copyback: false
prepare: |
pkg install -y curl
curl https://sh.rustup.rs -sSf --output rustup.sh
sh rustup.sh -y --profile minimal --default-toolchain stable
run: |
export PATH="$HOME/.cargo/bin:$PATH"
echo "===== rustc --version ====="
rustc --version
echo "===== freebsd-version ====="
freebsd-version
cargo build --locked --all-targets && cargo test --locked && cargo test --locked -- --ignored stress && cargo test --locked -p noq-udp --benches
build-solaris:
# Tests disabled - too many hang in poll() on Solaris
timeout-minutes: 45
name: build on solaris
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: build on Solaris
uses: vmactions/solaris-vm@v1
with:
release: "11.4-gcc"
usesh: true
mem: 4096
copyback: false
prepare: |
source <(curl -s https://raw.githubusercontent.com/psumbera/solaris-rust/refs/heads/main/sh.rust-web-install)
echo "~~~~ rustc --version ~~~~"
rustc --version
echo "~~~~ Solaris-version ~~~~"
uname -a
run: |
export PATH=$HOME/.rust_solaris/bin:$PATH
# Workaround for https://github.com/quinn-rs/quinn/issues/2218
export CARGO_HTTP_MULTIPLEXING=false
cargo build --locked --all-targets
test-illumos:
timeout-minutes: 45
name: test on illumos
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: test on Illumos
# pinned: v1 tag moves and builder v2.0.3+ ships a VM with broken DNS
uses: vmactions/omnios-vm@4f4fcbf0847b079a6e0eafe6ff06b3d15510f0b0
with:
usesh: true
mem: 4096
copyback: false
prepare: |
pkg install gcc14 curl pkg-config glib2
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal
run: |
. "$HOME/.cargo/env"
cargo build --locked --all-targets && cargo test --locked && cargo test --locked -- --ignored stress && cargo test --locked -p noq-udp --benches
features:
name: Feature powerset check
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
include:
- os: linux
runs-on: [self-hosted, linux, X64]
- os: macos
runs-on: [self-hosted, macOS, ARM64]
runs-on: ${{ matrix.runs-on }}
env:
RUSTFLAGS: -Dwarnings
# skip FIPS features outside of Linux
SKIP_FEATURES: ${{ matrix.os != 'linux' && 'aws-lc-rs-fips,aws-lc-fips-sys,__rustls-post-quantum-test' || '' }}
steps:
- uses: actions/checkout@v6
- uses: dtolnay/rust-toolchain@stable
- uses: taiki-e/install-action@cargo-hack
- name: Setup Go (required for aws-lc-rs FIPS)
if: matrix.os == 'linux'
uses: actions/setup-go@v5
with:
go-version: 'stable'
- run: cargo hack check --feature-powerset --depth 3 --optional-deps --no-dev-deps --ignore-private --skip "${{env.SKIP_FEATURES}}"
notify:
timeout-minutes: 45
needs: [proptests, test-freebsd, build-solaris, test-illumos, features]
if: ${{ always() }}
runs-on: ubuntu-latest
steps:
- name: Extract test results
run: |
printf '${{ toJSON(needs) }}\n'
proptests_result=$(echo '${{ toJSON(needs) }}' | jq -r '.proptests.result')
freebsd_result=$(echo '${{ toJSON(needs) }}' | jq -r '.["test-freebsd"].result')
solaris_result=$(echo '${{ toJSON(needs) }}' | jq -r '.["build-solaris"].result')
illumos_result=$(echo '${{ toJSON(needs) }}' | jq -r '.["test-illumos"].result')
features_result=$(echo '${{ toJSON(needs) }}' | jq -r '.features.result')
# Check if any failed
if [ "$proptests_result" = "failure" ] || [ "$freebsd_result" = "failure" ] || [ "$solaris_result" = "failure" ] || [ "$illumos_result" = "failure" ] || [ "$features_result" = "failure" ]; then
echo "TESTS_RESULT=failure" >>"$GITHUB_ENV"
else
echo "TESTS_RESULT=success" >>"$GITHUB_ENV"
fi
# Build failure details
details=""
[ "$proptests_result" = "failure" ] && details="${details}- Proptests failed\n"
[ "$freebsd_result" = "failure" ] && details="${details}- FreeBSD tests failed\n"
[ "$solaris_result" = "failure" ] && details="${details}- Solaris build failed\n"
[ "$illumos_result" = "failure" ] && details="${details}- Illumos tests failed\n"
[ "$features_result" = "failure" ] && details="${details}- Feature powerset check failed\n"
echo "FAILURE_DETAILS<<EOF" >>"$GITHUB_ENV"
echo -e "$details" >>"$GITHUB_ENV"
echo "EOF" >>"$GITHUB_ENV"
- name: Notify discord on failure
uses: n0-computer/discord-webhook-notify@v1
if: ${{ env.TESTS_RESULT == 'failure' }}
with:
text: "Daily CI failures in **${{ github.repository }}**"
severity: warn
details: |
${{ env.FAILURE_DETAILS }}
See https://github.com/${{ github.repository }}/actions/workflows/daily.yaml
webhookUrl: ${{ secrets.DISCORD_N0_GITHUB_CHANNEL_WEBHOOK_URL }}