diff --git a/contrib/localnet/scripts/start-zetaclientd.sh b/contrib/localnet/scripts/start-zetaclientd.sh index 93fa5c2af6..016dc8fbcf 100755 --- a/contrib/localnet/scripts/start-zetaclientd.sh +++ b/contrib/localnet/scripts/start-zetaclientd.sh @@ -115,4 +115,9 @@ if [[ -f /root/zetaclient-config-overlay.json ]]; then mv /tmp/merged_config.json /root/.zetacored/config/zetaclient_config.json fi +# signet +export CHAIN_18333_SCAN_FROM_BLOCK=latest +# testnet4 +export CHAIN_18334_SCAN_FROM_BLOCK=latest + zetaclientd-supervisor start < /root/password.file \ No newline at end of file diff --git a/contrib/localnet/scripts/zetaclient-config-overlay.json b/contrib/localnet/scripts/zetaclient-config-overlay.json new file mode 100644 index 0000000000..a66aad5faf --- /dev/null +++ b/contrib/localnet/scripts/zetaclient-config-overlay.json @@ -0,0 +1,26 @@ +{ + "BTCChainConfigs": { + "18444": { + "RPCUsername": "smoketest", + "RPCPassword": "123", + "RPCHost": "bitcoin:18443", + "RPCParams": "regtest", + "RPCAlertLatency": 60 + }, + "18333": { + "RPCUsername": "default", + "RPCPassword": "default", + "RPCHost": "172.17.0.1:38332", + "RPCParams": "testnet3", + "RPCAlertLatency": 60 + }, + "18334": { + "RPCUsername": "default", + "RPCPassword": "default", + "RPCHost": "172.17.0.1:48332", + "RPCParams": "testnet3", + "RPCAlertLatency": 60 + + } + } +} diff --git a/e2e/txserver/zeta_tx_server.go b/e2e/txserver/zeta_tx_server.go index 146dda4cf2..2eb7fe3602 100644 --- a/e2e/txserver/zeta_tx_server.go +++ b/e2e/txserver/zeta_tx_server.go @@ -453,6 +453,26 @@ func (zts ZetaTxServer) DeployZRC20s( coin.CoinType_Gas, 100000, ), + fungibletypes.NewMsgDeployFungibleCoinZRC20( + deployerAddr, + "", + chains.BitcoinSignetTestnet.ChainId, + 8, + "BTC", + "tBTC", + coin.CoinType_Gas, + 100000, + ), + fungibletypes.NewMsgDeployFungibleCoinZRC20( + deployerAddr, + "", + chains.BitcoinTestnet4.ChainId, + 8, + "BTC", + "tBTC", + coin.CoinType_Gas, + 100000, + ), fungibletypes.NewMsgDeployFungibleCoinZRC20( deployerAddr, "", diff --git a/x/observer/genesis.go b/x/observer/genesis.go index 12a92887c2..9d101b6624 100644 --- a/x/observer/genesis.go +++ b/x/observer/genesis.go @@ -24,6 +24,10 @@ func InitGenesis(ctx sdk.Context, k keeper.Keeper, genState types.GenesisState) // if no chain params are defined, set localnet chains for test purposes btcChainParams := types.GetDefaultBtcRegtestChainParams() btcChainParams.IsSupported = true + btcChainTestnet4Params := types.GetDefaultBtcTestnet4ChainParams() + btcChainTestnet4Params.IsSupported = true + btcChainSignetParams := types.GetDefaultBtcSignetChainParams() + btcChainSignetParams.IsSupported = true goerliChainParams := types.GetDefaultGoerliLocalnetChainParams() goerliChainParams.IsSupported = true zetaPrivnetChainParams := types.GetDefaultZetaPrivnetChainParams() @@ -31,6 +35,8 @@ func InitGenesis(ctx sdk.Context, k keeper.Keeper, genState types.GenesisState) k.SetChainParamsList(ctx, types.ChainParamsList{ ChainParams: []*types.ChainParams{ btcChainParams, + btcChainTestnet4Params, + btcChainSignetParams, goerliChainParams, zetaPrivnetChainParams, }, diff --git a/x/observer/types/chain_params.go b/x/observer/types/chain_params.go index b76af2da49..e39bc8b59b 100644 --- a/x/observer/types/chain_params.go +++ b/x/observer/types/chain_params.go @@ -146,6 +146,8 @@ func GetDefaultChainParams() ChainParamsList { GetDefaultBscTestnetChainParams(), GetDefaultMumbaiTestnetChainParams(), GetDefaultBtcTestnetChainParams(), + GetDefaultBtcTestnet4ChainParams(), + GetDefaultBtcSignetChainParams(), GetDefaultBtcRegtestChainParams(), GetDefaultGoerliLocalnetChainParams(), }, @@ -279,6 +281,42 @@ func GetDefaultBtcTestnetChainParams() *ChainParams { IsSupported: false, } } +func GetDefaultBtcTestnet4ChainParams() *ChainParams { + return &ChainParams{ + ChainId: chains.BitcoinTestnet4.ChainId, + ConfirmationCount: 2, + ZetaTokenContractAddress: constant.EVMZeroAddress, + ConnectorContractAddress: constant.EVMZeroAddress, + Erc20CustodyContractAddress: constant.EVMZeroAddress, + WatchUtxoTicker: 30, + InboundTicker: 120, + OutboundTicker: 12, + GasPriceTicker: 30, + OutboundScheduleInterval: 30, + OutboundScheduleLookahead: 100, + BallotThreshold: DefaultBallotThreshold, + MinObserverDelegation: DefaultMinObserverDelegation, + IsSupported: false, + } +} +func GetDefaultBtcSignetChainParams() *ChainParams { + return &ChainParams{ + ChainId: chains.BitcoinSignetTestnet.ChainId, + ConfirmationCount: 2, + ZetaTokenContractAddress: constant.EVMZeroAddress, + ConnectorContractAddress: constant.EVMZeroAddress, + Erc20CustodyContractAddress: constant.EVMZeroAddress, + WatchUtxoTicker: 30, + InboundTicker: 120, + OutboundTicker: 12, + GasPriceTicker: 30, + OutboundScheduleInterval: 30, + OutboundScheduleLookahead: 100, + BallotThreshold: DefaultBallotThreshold, + MinObserverDelegation: DefaultMinObserverDelegation, + IsSupported: false, + } +} func GetDefaultBtcRegtestChainParams() *ChainParams { return &ChainParams{ ChainId: chains.BitcoinRegtest.ChainId,