Skip to content

Commit

Permalink
fix build & collator script (#472)
Browse files Browse the repository at this point in the history
* fix build & collator script

* use submodule

* fix missing reserve_factor

* update specs module's commit
  • Loading branch information
GopherJ authored Aug 26, 2021
1 parent 8cc97bb commit f029505
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 122 deletions.
1 change: 1 addition & 0 deletions .github/workflows/dockerimage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
uses: actions/checkout@v2
with:
lfs: true
submodules: true
- name: Checkout LFS objects
run: git lfs checkout
- name: Set up QEMU
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "resources/specs"]
path = resources/specs
url = https://github.com/parallel-finance/specs
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,7 @@ wasm:

.PHONY: spec
spec:
docker run --rm parallelfinance/parallel:latest build-spec --chain $(CHAIN) --disable-default-bootnode > ./resources/$(CHAIN)-plain.json
docker run --rm -v $(PWD)/resources:/app/resources parallelfinance/parallel:latest build-spec --chain=/app/resources/$(CHAIN)-plain.json --raw --disable-default-bootnode > ./resources/$(CHAIN)-raw.json
docker run --rm parallelfinance/parallel:latest build-spec --chain $(CHAIN) --disable-default-bootnode --raw > ./resources/$(CHAIN)-raw.json

.PHONY: image
image:
Expand Down
115 changes: 0 additions & 115 deletions node/parallel/res/heiko.json

This file was deleted.

2 changes: 1 addition & 1 deletion node/parallel/src/chain_spec/heiko.rs
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ pub fn heiko_dev_config(id: ParaId) -> ChainSpec {
}

pub fn heiko_config(_id: ParaId) -> Result<ChainSpec, String> {
ChainSpec::from_json_bytes(&include_bytes!("../../res/heiko.json")[..])
ChainSpec::from_json_bytes(&include_bytes!("../../../../resources/specs/heiko.json")[..])
// Ok(ChainSpec::from_genesis(
// // Name
// "Heiko",
Expand Down
1 change: 1 addition & 0 deletions resources/specs
Submodule specs added at a25c4a
2 changes: 1 addition & 1 deletion runtime/heiko/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1402,7 +1402,7 @@ impl_runtime_apis! {

list_benchmark!(list, extra, pallet_balances, Balances);
list_benchmark!(list, extra, pallet_membership, TechnicalCommitteeMembership);
list_benchmark!(list, extra, pallet_liquid_staking, LiquidStaking);
// list_benchmark!(list, extra, pallet_liquid_staking, LiquidStaking);
list_benchmark!(list, extra, pallet_multisig, Multisig);
list_benchmark!(list, extra, pallet_loans, LoansBench::<Runtime>);
list_benchmark!(list, extra, frame_system, SystemBench::<Runtime>);
Expand Down
7 changes: 4 additions & 3 deletions scripts/collator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ PARA_RPC_PORT=9940
PARA_P2P_PORT=30340

PARA_CHAIN="heiko"
RELAY_CHAIN="kusama"
RELAY_CHAIN="westend"
VOLUME="chains"
NODE_KEY="$1"
KEYSTORE_PATH="$2"
Expand All @@ -35,13 +35,14 @@ docker run --restart=always --name heiko-collator \
-p $RELAY_RPC_PORT:$RELAY_RPC_PORT \
-p $RELAY_P2P_PORT:$RELAY_P2P_PORT \
-v "$VOLUME:/data" \
-v "$KEYSTORE_PATH:/app/keystore" \
parallelfinance/parallel:latest \
-d /data \
--chain=$RARA_CHAIN \
--chain=$PARA_CHAIN \
--validator \
--ws-port=$PARA_WS_PORT \
--rpc-port=$PARA_RPC_PORT \
--keystore-path=$KEYSTORE_PATH \
--keystore-path=/app/keystore \
--node-key=$NODE_KEY \
--ws-external \
--rpc-external \
Expand Down

0 comments on commit f029505

Please sign in to comment.