Skip to content

Commit f556517

Browse files
committed
CI check
1 parent 067bc58 commit f556517

File tree

2 files changed

+63
-0
lines changed

2 files changed

+63
-0
lines changed

.github/workflows/butterflynet.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Butterflynet checks
2+
concurrency:
3+
group: "${{ github.workflow }}-${{ github.ref }}"
4+
cancel-in-progress: "${{ github.ref != 'refs/heads/main' }}"
5+
"on":
6+
workflow_dispatch:
7+
# TODO: disable for PR
8+
pull_request:
9+
branches:
10+
- main
11+
env:
12+
CI: 1
13+
CARGO_INCREMENTAL: 0
14+
CACHE_TIMEOUT_MINUTES: 5
15+
SCRIPT_TIMEOUT_MINUTES: 30
16+
AWS_ACCESS_KEY_ID: "${{ secrets.AWS_ACCESS_KEY_ID }}"
17+
AWS_SECRET_ACCESS_KEY: "${{ secrets.AWS_SECRET_ACCESS_KEY }}"
18+
RUSTC_WRAPPER: sccache
19+
CC: sccache clang
20+
CXX: sccache clang++
21+
FIL_PROOFS_PARAMETER_CACHE: /var/tmp/filecoin-proof-parameters
22+
SHELL_IMAGE: busybox
23+
jobs:
24+
butterflynet-checks:
25+
name: Butterflynet checks
26+
runs-on: ubuntu-24.04
27+
steps:
28+
- name: Checkout Sources
29+
uses: actions/checkout@v4
30+
- name: Setup sccache
31+
uses: mozilla-actions/sccache-action@v0.0.7
32+
timeout-minutes: "${{ fromJSON(env.CACHE_TIMEOUT_MINUTES) }}"
33+
continue-on-error: true
34+
- uses: actions/setup-go@v5
35+
with:
36+
go-version-file: "go.work"
37+
- name: Build and install Forest binaries
38+
env:
39+
# To minimize compile times: https://nnethercote.github.io/perf-book/build-configuration.html#minimizing-compile-times
40+
RUSTFLAGS: "-C linker=clang -C link-arg=-fuse-ld=lld"
41+
run: make install-slim-quick
42+
- name: Run butterflynet checks
43+
run: ./scripts/tests/butterflynet_check.sh
44+
timeout-minutes: "${{ fromJSON(env.SCRIPT_TIMEOUT_MINUTES) }}"
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/bin/bash
2+
set -euxo pipefail
3+
4+
# This script tests Forest is able to catch up the butterflynet.
5+
6+
source "$(dirname "$0")/harness.sh"
7+
8+
$FOREST_PATH --chain butterflynet --encrypt-keystore false &
9+
FOREST_NODE_PID=$!
10+
11+
$FOREST_CLI_PATH healthcheck live --wait
12+
13+
forest_wait_for_sync
14+
15+
function shutdown {
16+
kill -KILL $FOREST_NODE_PID
17+
}
18+
19+
trap shutdown EXIT

0 commit comments

Comments
 (0)