Skip to content

Commit 058bcbb

Browse files
marc0oloclaude
andcommitted
chore: migrate from dfx to icp-cli
- Replace dfx install with icp-cli in provision-darwin.sh and provision-linux.sh - Add actions/setup-node v22 step to frontend.yml and all example workflows (required by icp-cli which needs Node.js >=22) - Replace dfx.json with icp.yaml in backend Motoko and Rust canisters - Update backend Makefiles to use icp instead of dfx - Update Rust integration tests to use icp canister IDs - Remove root dfx.json Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent b9c9418 commit 058bcbb

30 files changed

Lines changed: 301 additions & 217 deletions

.github/workflows/examples-basic-bls-signing.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,16 @@ on:
1515
concurrency:
1616
group: ${{ github.workflow }}-${{ github.ref }}
1717
cancel-in-progress: true
18-
env:
19-
DFX_VERSION: 0.29.1
2018
jobs:
2119
examples-basic-bls-signing-rust-darwin:
2220
runs-on: macos-15
2321
steps:
2422
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
2523
with:
2624
persist-credentials: false
25+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
26+
with:
27+
node-version: '22'
2728
- name: Provision Darwin
2829
run: |
2930
bash .github/workflows/provision-darwin.sh
@@ -32,7 +33,7 @@ jobs:
3233
set -eExuo pipefail
3334
cargo install candid-extractor
3435
pushd examples/basic_bls_signing/rust
35-
dfx start --background && dfx deploy
36+
icp network start -d && icp deploy
3637
cd frontend
3738
npm run lint
3839
examples-basic-bls-signing-rust-linux:
@@ -41,14 +42,17 @@ jobs:
4142
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
4243
with:
4344
persist-credentials: false
45+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
46+
with:
47+
node-version: '22'
4448
- name: Provision Linux
4549
run: bash .github/workflows/provision-linux.sh
4650
- name: Deploy Basic BLS Signing Rust Linux
4751
run: |
4852
set -eExuo pipefail
4953
cargo install candid-extractor
5054
pushd examples/basic_bls_signing/rust
51-
dfx start --background && dfx deploy
55+
icp network start -d && icp deploy
5256
cd frontend
5357
npm run lint
5458
examples-basic-bls-signing-motoko-darwin:
@@ -57,6 +61,9 @@ jobs:
5761
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
5862
with:
5963
persist-credentials: false
64+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
65+
with:
66+
node-version: '22'
6067
- name: Provision Darwin
6168
run: |
6269
bash .github/workflows/provision-darwin.sh
@@ -65,7 +72,7 @@ jobs:
6572
set -eExuo pipefail
6673
cargo install candid-extractor
6774
pushd examples/basic_bls_signing/motoko
68-
dfx start --background && dfx deploy
75+
icp network start -d && icp deploy
6976
cd frontend
7077
npm run lint
7178
examples-basic-bls-signing-motoko-linux:
@@ -74,13 +81,16 @@ jobs:
7481
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
7582
with:
7683
persist-credentials: false
84+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
85+
with:
86+
node-version: '22'
7787
- name: Provision Linux
7888
run: bash .github/workflows/provision-linux.sh
7989
- name: Deploy Basic BLS Signing Motoko Linux
8090
run: |
8191
set -eExuo pipefail
8292
cargo install candid-extractor
8393
pushd examples/basic_bls_signing/motoko
84-
dfx start --background && dfx deploy
94+
icp network start -d && icp deploy
8595
cd frontend
8696
npm run lint

.github/workflows/examples-basic-ibe.yml

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,16 @@ on:
1414
concurrency:
1515
group: ${{ github.workflow }}-${{ github.ref }}
1616
cancel-in-progress: true
17-
env:
18-
DFX_VERSION: 0.29.1
1917
jobs:
2018
examples-basic-ibe-rust-darwin:
2119
runs-on: macos-15
2220
steps:
2321
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
2422
with:
2523
persist-credentials: false
24+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
25+
with:
26+
node-version: '22'
2627
- name: Provision Darwin
2728
run: |
2829
bash .github/workflows/provision-darwin.sh
@@ -31,7 +32,7 @@ jobs:
3132
set -eExuo pipefail
3233
cargo install candid-extractor
3334
pushd examples/basic_ibe/rust
34-
dfx start --background && dfx deploy
35+
icp network start -d && icp deploy
3536
cd frontend
3637
npm run lint
3738
examples-basic-ibe-rust-linux:
@@ -40,14 +41,17 @@ jobs:
4041
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
4142
with:
4243
persist-credentials: false
44+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
45+
with:
46+
node-version: '22'
4347
- name: Provision Linux
4448
run: bash .github/workflows/provision-linux.sh
4549
- name: Deploy Basic IBE Rust Linux
4650
run: |
4751
set -eExuo pipefail
4852
cargo install candid-extractor
4953
pushd examples/basic_ibe/rust
50-
dfx start --background && dfx deploy
54+
icp network start -d && icp deploy
5155
cd frontend
5256
npm run lint
5357
examples-basic-ibe-motoko-darwin:
@@ -56,6 +60,9 @@ jobs:
5660
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
5761
with:
5862
persist-credentials: false
63+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
64+
with:
65+
node-version: '22'
5966
- name: Provision Darwin
6067
run: |
6168
bash .github/workflows/provision-darwin.sh
@@ -64,7 +71,7 @@ jobs:
6471
set -eExuo pipefail
6572
cargo install candid-extractor
6673
pushd examples/basic_ibe/motoko
67-
dfx start --background && dfx deploy
74+
icp network start -d && icp deploy
6875
cd frontend
6976
npm run lint
7077
examples-basic-ibe-motoko-linux:
@@ -73,13 +80,16 @@ jobs:
7380
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
7481
with:
7582
persist-credentials: false
83+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
84+
with:
85+
node-version: '22'
7686
- name: Provision Linux
7787
run: bash .github/workflows/provision-linux.sh
7888
- name: Deploy Basic IBE Motoko Linux
7989
run: |
8090
set -eExuo pipefail
8191
cargo install candid-extractor
8292
pushd examples/basic_ibe/motoko
83-
dfx start --background && dfx deploy
93+
icp network start -d && icp deploy
8494
cd frontend
85-
npm run lint
95+
npm run lint

.github/workflows/examples-basic-timelock-ibe.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ jobs:
2222
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
2323
with:
2424
persist-credentials: false
25+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
26+
with:
27+
node-version: '22'
2528
- name: Provision Darwin
2629
run: |
2730
bash .github/workflows/provision-darwin.sh
@@ -30,7 +33,7 @@ jobs:
3033
set -eExuo pipefail
3134
cargo install candid-extractor
3235
pushd examples/basic_timelock_ibe
33-
dfx start --background && dfx deploy
36+
icp network start -d && icp deploy
3437
cd frontend
3538
npm run lint
3639
examples-basic-timelock-ibe-rust-linux:
@@ -39,13 +42,16 @@ jobs:
3942
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
4043
with:
4144
persist-credentials: false
45+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
46+
with:
47+
node-version: '22'
4248
- name: Provision Linux
4349
run: bash .github/workflows/provision-linux.sh
4450
- name: Deploy Basic Timelock IBE Linux
4551
run: |
4652
set -eExuo pipefail
4753
cargo install candid-extractor
4854
pushd examples/basic_timelock_ibe
49-
dfx start --background && dfx deploy
55+
icp network start -d && icp deploy
5056
cd frontend
51-
npm run lint
57+
npm run lint

.github/workflows/examples-encrypted-chat.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ jobs:
2020
runs-on: macos-15
2121
steps:
2222
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
23+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
24+
with:
25+
node-version: '22'
2326
- name: Provision Darwin
2427
run: |
2528
bash .github/workflows/provision-darwin.sh
@@ -32,6 +35,9 @@ jobs:
3235
runs-on: ubuntu-24.04
3336
steps:
3437
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
38+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
39+
with:
40+
node-version: '22'
3541
- name: Provision Linux
3642
run: bash .github/workflows/provision-linux.sh
3743
- name: Backend Tests Encrypted Chat Rust Linux

.github/workflows/examples-encrypted-notes-dapp.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,60 +14,70 @@ on:
1414
concurrency:
1515
group: ${{ github.workflow }}-${{ github.ref }}
1616
cancel-in-progress: true
17-
env:
18-
DFX_VERSION: 0.29.1
1917
jobs:
2018
examples-encrypted-notes-dapp-rust-darwin:
2119
runs-on: macos-15
2220
steps:
2321
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
2422
with:
2523
persist-credentials: false
24+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
25+
with:
26+
node-version: '22'
2627
- name: Provision Darwin
2728
run: |
2829
bash .github/workflows/provision-darwin.sh
2930
- name: Deploy Encrypted Notes Dapp VetKD Darwin
3031
run: |
3132
set -eExuo pipefail
3233
cd examples/encrypted_notes_dapp_vetkd/rust
33-
dfx start --background && dfx deploy
34+
icp network start -d && icp deploy
3435
examples-encrypted-notes-dapp-rust-linux:
3536
runs-on: ubuntu-24.04
3637
steps:
3738
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
3839
with:
3940
persist-credentials: false
41+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
42+
with:
43+
node-version: '22'
4044
- name: Provision Linux
4145
run: bash .github/workflows/provision-linux.sh
4246
- name: Deploy Encrypted Notes Dapp VetKD Linux
4347
run: |
4448
set -eExuo pipefail
4549
cd examples/encrypted_notes_dapp_vetkd/rust
46-
dfx start --background && dfx deploy
50+
icp network start -d && icp deploy
4751
examples-encrypted-notes-dapp-motoko-darwin:
4852
runs-on: macos-15
4953
steps:
5054
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
5155
with:
5256
persist-credentials: false
57+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
58+
with:
59+
node-version: '22'
5360
- name: Provision Darwin
5461
run: |
5562
bash .github/workflows/provision-darwin.sh
5663
- name: Deploy Encrypted Notes Dapp VetKD Darwin
5764
run: |
5865
set -eExuo pipefail
5966
cd examples/encrypted_notes_dapp_vetkd/motoko
60-
dfx start --background && dfx deploy
67+
icp network start -d && icp deploy
6168
examples-encrypted-notes-dapp-motoko-linux:
6269
runs-on: ubuntu-24.04
6370
steps:
6471
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
6572
with:
6673
persist-credentials: false
74+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
75+
with:
76+
node-version: '22'
6777
- name: Provision Linux
6878
run: bash .github/workflows/provision-linux.sh
6979
- name: Deploy Encrypted Notes Dapp VetKD Linux
7080
run: |
7181
set -eExuo pipefail
7282
cd examples/encrypted_notes_dapp_vetkd/motoko
73-
dfx start --background && dfx deploy
83+
icp network start -d && icp deploy

.github/workflows/examples-password-manager-with-metadata.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,16 @@ on:
1616
concurrency:
1717
group: ${{ github.workflow }}-${{ github.ref }}
1818
cancel-in-progress: true
19-
env:
20-
DFX_VERSION: 0.29.1
2119
jobs:
2220
examples-password-manager-with-metadata-rust-darwin:
2321
runs-on: macos-15
2422
steps:
2523
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
2624
with:
2725
persist-credentials: false
26+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
27+
with:
28+
node-version: '22'
2829
- name: Provision Darwin
2930
run: |
3031
bash .github/workflows/provision-darwin.sh
@@ -33,7 +34,7 @@ jobs:
3334
set -eExuo pipefail
3435
cargo install candid-extractor
3536
cd examples/password_manager_with_metadata/rust
36-
dfx start --background && dfx deploy
37+
icp network start -d && icp deploy
3738
cd frontend
3839
npm run lint
3940
examples-password-manager-with-metadata-rust-linux:
@@ -42,14 +43,17 @@ jobs:
4243
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
4344
with:
4445
persist-credentials: false
46+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
47+
with:
48+
node-version: '22'
4549
- name: Provision Linux
4650
run: bash .github/workflows/provision-linux.sh
4751
- name: Deploy Password Manager With Metadata Linux
4852
run: |
4953
set -eExuo pipefail
5054
cargo install candid-extractor
5155
cd examples/password_manager_with_metadata/rust
52-
dfx start --background && dfx deploy
56+
icp network start -d && icp deploy
5357
cd frontend
5458
npm run lint
5559
examples-password-manager-with-metadata-motoko-darwin:
@@ -58,6 +62,9 @@ jobs:
5862
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
5963
with:
6064
persist-credentials: false
65+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
66+
with:
67+
node-version: '22'
6168
- name: Provision Darwin
6269
run: |
6370
bash .github/workflows/provision-darwin.sh
@@ -66,7 +73,7 @@ jobs:
6673
set -eExuo pipefail
6774
cargo install candid-extractor
6875
cd examples/password_manager_with_metadata/motoko
69-
dfx start --background && dfx deploy
76+
icp network start -d && icp deploy
7077
cd frontend
7178
npm run lint
7279
examples-password-manager-with-metadata-motoko-linux:
@@ -75,13 +82,16 @@ jobs:
7582
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
7683
with:
7784
persist-credentials: false
85+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
86+
with:
87+
node-version: '22'
7888
- name: Provision Linux
7989
run: bash .github/workflows/provision-linux.sh
8090
- name: Deploy Password Manager With Metadata Linux
8191
run: |
8292
set -eExuo pipefail
8393
cargo install candid-extractor
8494
cd examples/password_manager_with_metadata/motoko
85-
dfx start --background && dfx deploy
95+
icp network start -d && icp deploy
8696
cd frontend
8797
npm run lint

0 commit comments

Comments
 (0)