hive script: move HIVE_CLIQUE_PERIOD processing from nimbus.sh to mapper.jq
This commit is contained in:
parent
a05f366ca2
commit
dcbbfd08ae
|
@ -52,6 +52,9 @@ def to_bool:
|
||||||
"baseFeePerGas": .baseFeePerGas
|
"baseFeePerGas": .baseFeePerGas
|
||||||
}|remove_empty,
|
}|remove_empty,
|
||||||
"config": {
|
"config": {
|
||||||
|
"clique": (if env.HIVE_CLIQUE_PERIOD == null then null else {
|
||||||
|
"period": env.HIVE_CLIQUE_PERIOD|to_int,
|
||||||
|
} end),
|
||||||
"chainId": env.HIVE_CHAIN_ID|to_int,
|
"chainId": env.HIVE_CHAIN_ID|to_int,
|
||||||
"homesteadBlock": env.HIVE_FORK_HOMESTEAD|to_int,
|
"homesteadBlock": env.HIVE_FORK_HOMESTEAD|to_int,
|
||||||
"daoForkBlock": env.HIVE_FORK_DAO_BLOCK|to_int,
|
"daoForkBlock": env.HIVE_FORK_DAO_BLOCK|to_int,
|
||||||
|
|
|
@ -64,13 +64,10 @@ if [ "$HIVE_NETWORK_ID" != "" ]; then
|
||||||
FLAGS="$FLAGS --networkid:$HIVE_NETWORK_ID"
|
FLAGS="$FLAGS --networkid:$HIVE_NETWORK_ID"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$HIVE_CLIQUE_PERIOD" != "" ]; then
|
|
||||||
FLAGS="$FLAGS --clique-period:$HIVE_CLIQUE_PERIOD"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$HIVE_CLIQUE_PRIVATEKEY" != "" ]; then
|
if [ "$HIVE_CLIQUE_PRIVATEKEY" != "" ]; then
|
||||||
echo "$HIVE_CLIQUE_PRIVATEKEY" > /private.key
|
# -n will prevent newline when echoing something
|
||||||
FLAGS="$FLAGS --import-key:/private.key"
|
echo -n "$HIVE_CLIQUE_PRIVATEKEY" > private.key
|
||||||
|
FLAGS="$FLAGS --import-key:private.key"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$HIVE_MINER" != "" ]; then
|
if [ "$HIVE_MINER" != "" ]; then
|
||||||
|
|
Loading…
Reference in New Issue