Skip to content

Commit 8fba749

Browse files
Merge branch 'main' into ray-align-storage-period
2 parents b1a9c40 + 31ed9f1 commit 8fba749

File tree

5 files changed

+231
-130
lines changed

5 files changed

+231
-130
lines changed

.github/workflows/check.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
run: echo "CI_IMAGE=${{ env.CI_IMAGE }}" >> $GITHUB_OUTPUT
3535

3636
check-fmt:
37-
runs-on: ubuntu-latest
37+
runs-on: parity-default
3838
timeout-minutes: 20
3939
needs: [set-image]
4040
container:
@@ -57,7 +57,6 @@ jobs:
5757
5858
check:
5959
name: Cargo check
60-
# TODO: replace `parity-default` with `ubuntu-latest` when the repo becomes public.
6160
runs-on: parity-default
6261
needs: [set-image, check-fmt]
6362
container:
@@ -77,7 +76,6 @@ jobs:
7776

7877
check-benchmarking:
7978
name: Cargo check (benchmarking)
80-
# TODO: replace `parity-default` with `ubuntu-latest` when the repo becomes public.
8179
runs-on: parity-default
8280
needs: [set-image, check]
8381
container:
@@ -98,7 +96,6 @@ jobs:
9896
9997
clippy:
10098
name: Cargo clippy
101-
# TODO: replace `parity-default` with `ubuntu-latest` when the repo becomes public.
10299
runs-on: parity-default
103100
needs: [set-image, check]
104101
container:
@@ -123,7 +120,6 @@ jobs:
123120
124121
test:
125122
name: Test
126-
# TODO: replace `parity-default` with `ubuntu-latest` when the repo becomes public.
127123
runs-on: parity-default
128124
timeout-minutes: 60
129125
needs: [set-image, check]
Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
name: Integration Tests
2+
3+
# Controls when the action will run.
4+
on:
5+
# Triggers the workflow on push or pull request events but only for the master branch
6+
push:
7+
branches: [main]
8+
pull_request:
9+
branches: [main]
10+
11+
# Allows you to run this workflow manually from the Actions tab
12+
workflow_dispatch:
13+
14+
# Cancel previous runs
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
17+
cancel-in-progress: true
18+
19+
# Parity CI image to use
20+
# Common variable is defined in the workflow
21+
# Repo env variable doesn't work for PRs from forks
22+
env:
23+
CI_IMAGE: "paritytech/ci-unified:bullseye-1.88.0-2025-06-27-v202507112050"
24+
NODE_VERSION: 22
25+
26+
jobs:
27+
set-image:
28+
# This workaround sets the container image for each job using 'set-image' job output.
29+
# env variables don't work for PRs from forks, so we need to use outputs.
30+
runs-on: ubuntu-latest
31+
outputs:
32+
CI_IMAGE: ${{ steps.set_image.outputs.CI_IMAGE }}
33+
steps:
34+
- id: set_image
35+
run: echo "CI_IMAGE=${{ env.CI_IMAGE }}" >> $GITHUB_OUTPUT
36+
37+
integration-tests:
38+
name: Integration Tests
39+
runs-on: parity-default
40+
timeout-minutes: 60
41+
needs: [ set-image ]
42+
container:
43+
image: ${{ needs.set-image.outputs.CI_IMAGE }}
44+
45+
steps:
46+
- name: Checkout sources
47+
uses: actions/checkout@v4
48+
49+
- name: Rust cache
50+
uses: Swatinem/rust-cache@v2
51+
with:
52+
cache-on-failure: true
53+
cache-all-crates: true
54+
55+
- name: Setup Node.js
56+
uses: actions/setup-node@v4
57+
with:
58+
node-version: ${{ env.NODE_VERSION }}
59+
cache: 'npm'
60+
cache-dependency-path: examples/package.json
61+
62+
- name: Install just
63+
run: cargo install just --locked || true
64+
65+
- name: Download zombienet
66+
run: |
67+
curl -L \
68+
-H "Authorization: token ${{ github.token }}" \
69+
-o zombienet-linux-x64 \
70+
"https://github.com/paritytech/zombienet/releases/download/v1.3.138/zombienet-linux-x64"
71+
chmod +x zombienet-linux-x64
72+
echo "ZOMBIENET_BINARY=$GITHUB_WORKSPACE/zombienet-linux-x64" >> $GITHUB_ENV
73+
74+
- name: Run authorize and store (PAPI, smoldot)
75+
working-directory: examples
76+
run: just run-authorize-and-store "smoldot"
77+
78+
- name: Run authorize and store (PAPI, RPC node)
79+
working-directory: examples
80+
run: just run-authorize-and-store "ws"

examples/README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ tar -xvzf kubo_v0.38.1_darwin-arm64.tar.gz
7575

7676
#### Use Docker
7777

78-
* Use `172.17.0.1` or `host.docker.internal` for swarm connections
78+
* Use `host.docker.internal` (macOS/Windows) or `172.17.0.1` (Linux) for swarm connections
7979

8080
```shell
8181
docker pull ipfs/kubo:latest
@@ -107,7 +107,11 @@ POLKADOT_BULLETIN_BINARY_PATH=./target/release/polkadot-bulletin-chain \
107107
```
108108

109109
```shell
110-
# Uses Docker (replace 127.0.0.1 with 172.17.0.1)
110+
# Uses Docker on macOS/Windows (use dns4/host.docker.internal)
111+
docker exec -it ipfs-node ipfs swarm connect /dns4/host.docker.internal/tcp/10001/ws/p2p/12D3KooWQCkBm1BYtkHpocxCwMgR8yjitEeHGx8spzcDLGt2gkBm
112+
docker exec -it ipfs-node ipfs swarm connect /dns4/host.docker.internal/tcp/12347/ws/p2p/12D3KooWRkZhiRhsqmrQ28rt73K7V3aCBpqKrLGSXmZ99PTcTZby
113+
114+
# Uses Docker on Linux (use ip4/172.17.0.1)
111115
docker exec -it ipfs-node ipfs swarm connect /ip4/172.17.0.1/tcp/10001/ws/p2p/12D3KooWQCkBm1BYtkHpocxCwMgR8yjitEeHGx8spzcDLGt2gkBm
112116
docker exec -it ipfs-node ipfs swarm connect /ip4/172.17.0.1/tcp/12347/ws/p2p/12D3KooWRkZhiRhsqmrQ28rt73K7V3aCBpqKrLGSXmZ99PTcTZby
113117
```

0 commit comments

Comments
 (0)