diff --git a/vegacapsule/config.hcl b/vegacapsule/config.hcl index 8be0acd40..7aca9f010 100644 --- a/vegacapsule/config.hcl +++ b/vegacapsule/config.hcl @@ -4,7 +4,7 @@ network "testnet" { ethereum { chain_id = "1440" network_id = "1441" - endpoint = "http://127.0.0.1:8545/" + endpoint = "ws://127.0.0.1:8545/" } faucet "faucet-1" { @@ -43,7 +43,7 @@ EOT env = { POSTGRES_USER="vega" POSTGRES_PASSWORD="vega" - POSTGRES_DBS="vega0,vega1,vega2,vega3,vega4,vega5,vega6,vega7,vega8" + POSTGRES_DBS="vega0,vega1,vega2,vega3,vega4,vega5,vega6,vega7,vega8,vega9,vega10,vega11,vega12,vega13,vega14,vega15,vega16,vega17,vega18,vega19,vega20,vega21,vega22,vega23,vega24,vega25" } static_port { diff --git a/vegacapsule/node_set_templates/default/data_node_full_external_postgres.tmpl b/vegacapsule/node_set_templates/default/data_node_full_external_postgres.tmpl index 172bee780..eeb43d652 100644 --- a/vegacapsule/node_set_templates/default/data_node_full_external_postgres.tmpl +++ b/vegacapsule/node_set_templates/default/data_node_full_external_postgres.tmpl @@ -13,34 +13,47 @@ GatewayEnabled = true [API] Level = "Info" - Port = 30{{.NodeNumber}}7 - CoreNodeGRPCPort = 30{{.NodeNumber}}2 + Port = {{add 300 .NodeNumber}}7 + CoreNodeGRPCPort = {{add 300 .NodeNumber}}2 [Pprof] Level = "Info" Enabled = false - Port = 6{{.NodeNumber}}60 + Port = {{add 60 .NodeNumber}}60 ProfilesDir = "{{.NodeHomeDir}}" [Gateway] Level = "Info" [Gateway.Node] - Port = 30{{.NodeNumber}}7 + Port = {{add 300 .NodeNumber}}7 [Gateway.GraphQL] - Port = 30{{.NodeNumber}}8 + Port = {{add 300 .NodeNumber}}8 [Gateway.REST] - Port = 30{{.NodeNumber}}9 + Port = {{add 300 .NodeNumber}}9 [Metrics] Level = "Info" Timeout = "5s" - Port = 21{{.NodeNumber}}2 + Port = {{add 210 .NodeNumber}}2 Enabled = false [Broker] Level = "Info" UseEventFile = false [Broker.SocketConfig] - Port = 30{{.NodeNumber}}5 + Port = {{add 300 .NodeNumber}}5 [DeHistory] Enabled = true + [DeHistory.Store] + PeerID = "{{.GetDehistoryPeerID .NodeNumber}}" + PrivKey = "{{.GetDehistoryPrivKey .NodeNumber}}" + + BootstrapPeers = [{{- range $i, $peer := .IPSFPeers -}} + {{- if ne $i 0 }},{{end -}} + "/ip4/127.0.0.1/tcp/{{add 400 $peer.Index}}5/ipfs/{{ $peer.ID }}" + {{- end -}}] + + UseIpfsDefaultPeers = false + SwarmPort = 40{{.NodeNumber}}5 + StartWebUI = false + WebUIPort = 50{{.NodeNumber}}5 diff --git a/vegacapsule/node_set_templates/default/data_node_full_snapshots.tmpl b/vegacapsule/node_set_templates/default/data_node_full_snapshots.tmpl new file mode 100644 index 000000000..13ae2b0d1 --- /dev/null +++ b/vegacapsule/node_set_templates/default/data_node_full_snapshots.tmpl @@ -0,0 +1,65 @@ +GatewayEnabled = true +[SQLStore] + Enabled = true + [SQLStore.ConnectionConfig] + Database = "vega{{.NodeNumber}}" + Host = "localhost" + Password = "vega" + Port = 5232 + UseTransactions = true + Username = "vega" + +[API] + Level = "Info" + Port = {{add 300 .NodeNumber}}7 + CoreNodeGRPCPort = {{add 300 .NodeNumber}}2 + +[Pprof] + Level = "Info" + Enabled = true + Port = {{add 60 .NodeNumber}}60 + ProfilesDir = "{{.NodeHomeDir}}" + +[Gateway] + Level = "Info" + [Gateway.Node] + Port = {{add 300 .NodeNumber}}7 + [Gateway.GraphQL] + Port = {{add 300 .NodeNumber}}8 + [Gateway.REST] + Port = {{add 300 .NodeNumber}}9 + +[Metrics] + Level = "Info" + Timeout = "5s" + Port = {{add 210 .NodeNumber}}2 + Enabled = false +[Broker] + Level = "Info" + UseEventFile = false + PanicOnError = false + [Broker.SocketConfig] + Port = {{add 300 .NodeNumber}}5 + +[DeHistory] + Level = "Info" + Enabled = true + WipeOnStartup = true + AddSnapshotsToStore = true + AddSnapshotsInterval = "5s" + [DeHistory.Store] + PeerID = "{{.GetDehistoryPeerID .NodeNumber}}" + PrivKey = "{{.GetDehistoryPrivKey .NodeNumber}}" + + BootstrapPeers = [{{- range $i, $peer := .IPSFPeers -}} + {{- if ne $i 0 }},{{end -}} + "/ip4/127.0.0.1/tcp/{{add 400 $peer.Index}}5/ipfs/{{ $peer.ID }}" + {{- end -}}] + + UseIpfsDefaultPeers = false + SwarmPort = {{add 400 .NodeNumber}}5 + StartWebUI = false + WebUIPort = {{add 500 .NodeNumber}}5 + [DeHistory.Snapshot] + PanicOnSnapshotCreationError = true + WaitForCreationLockTimeout = "5s" diff --git a/vegacapsule/node_set_templates/default/tendermint_full.tmpl b/vegacapsule/node_set_templates/default/tendermint_full.tmpl index 71bdc56d3..79fbbf697 100644 --- a/vegacapsule/node_set_templates/default/tendermint_full.tmpl +++ b/vegacapsule/node_set_templates/default/tendermint_full.tmpl @@ -1,24 +1,24 @@ log_level = "info" -proxy_app = "tcp://127.0.0.1:266{{.NodeNumber}}8" -moniker = "{{.Prefix}}-{{.TendermintNodePrefix}}" +proxy_app = "tcp://127.0.0.1:{{add 2660 .NodeNumber}}8" +moniker = "{{.TendermintNodePrefix}}-{{.NodeNumber}}" [rpc] - laddr = "tcp://0.0.0.0:266{{.NodeNumber}}7" + laddr = "tcp://0.0.0.0:{{add 2660 .NodeNumber}}7" unsafe = true cors_allowed_origins = ["*"] cors_allowed_methods = ["HEAD", "GET", "POST", ] cors_allowed_headers = ["Origin", "Accept", "Content-Type", "X-Requested-With", "X-Server-Time", ] [p2p] - laddr = "tcp://0.0.0.0:266{{.NodeNumber}}6" + laddr = "tcp://0.0.0.0:{{add 2660 .NodeNumber}}6" addr_book_strict = false max_packet_msg_payload_size = 4096 pex = false allow_duplicate_ip = true persistent_peers = "{{- range $i, $peer := .NodePeers -}} {{- if ne $i 0 }},{{end -}} - {{- $peer.ID}}@127.0.0.1:266{{$peer.Index}}6 + {{- $peer.ID}}@127.0.0.1:{{add 2660 $peer.Index}}6 {{- end -}}" [mempool] diff --git a/vegacapsule/node_set_templates/default/tendermint_validators.tmpl b/vegacapsule/node_set_templates/default/tendermint_validators.tmpl index fa5e7b91b..f6e2190c8 100644 --- a/vegacapsule/node_set_templates/default/tendermint_validators.tmpl +++ b/vegacapsule/node_set_templates/default/tendermint_validators.tmpl @@ -1,17 +1,17 @@ log_level = "info" -proxy_app = "tcp://127.0.0.1:266{{.NodeNumber}}8" -moniker = "{{.Prefix}}-{{.TendermintNodePrefix}}" +proxy_app = "tcp://127.0.0.1:{{add 2660 .NodeNumber}}8" +moniker = "{{.TendermintNodePrefix}}-{{.NodeNumber}}" [rpc] - laddr = "tcp://0.0.0.0:266{{.NodeNumber}}7" + laddr = "tcp://0.0.0.0:{{add 2660 .NodeNumber}}7" unsafe = true cors_allowed_origins = ["*"] cors_allowed_methods = ["HEAD", "GET", "POST", ] cors_allowed_headers = ["Origin", "Accept", "Content-Type", "X-Requested-With", "X-Server-Time", ] [p2p] - laddr = "tcp://0.0.0.0:266{{.NodeNumber}}6" + laddr = "tcp://0.0.0.0:{{add 2660 .NodeNumber}}6" addr_book_strict = false max_packet_msg_payload_size = 4096 pex = false @@ -19,7 +19,7 @@ moniker = "{{.Prefix}}-{{.TendermintNodePrefix}}" persistent_peers = "{{- range $i, $peer := .NodePeers -}} {{- if ne $i 0 }},{{end -}} - {{- $peer.ID}}@127.0.0.1:266{{$peer.Index}}6 + {{- $peer.ID}}@127.0.0.1:{{add 2660 $peer.Index}}6 {{- end -}}" diff --git a/vegacapsule/node_set_templates/default/vega_full.tmpl b/vegacapsule/node_set_templates/default/vega_full.tmpl index 571aae6a2..bcdd52692 100644 --- a/vegacapsule/node_set_templates/default/vega_full.tmpl +++ b/vegacapsule/node_set_templates/default/vega_full.tmpl @@ -4,15 +4,15 @@ Enabled = true [API] - Port = 30{{.NodeNumber}}2 + Port = {{add 300 .NodeNumber}}2 [API.REST] - Port = 30{{.NodeNumber}}3 + Port = {{add 300 .NodeNumber}}3 [Blockchain] [Blockchain.Tendermint] - RPCAddr = "tcp://127.0.0.1:266{{.NodeNumber}}7" + RPCAddr = "tcp://127.0.0.1:{{add 2660 .NodeNumber}}7" [Blockchain.Null] - Port = 31{{.NodeNumber}}1 + Port = {{add 310 .NodeNumber}}1 [EvtForward] Level = "Info" @@ -28,5 +28,5 @@ [Broker] [Broker.Socket] - Port = 30{{.NodeNumber}}5 + Port = {{add 300 .NodeNumber}}5 Enabled = true diff --git a/vegacapsule/node_set_templates/default/vega_validators.tmpl b/vegacapsule/node_set_templates/default/vega_validators.tmpl index 6d25a06fb..1826e6b5b 100644 --- a/vegacapsule/node_set_templates/default/vega_validators.tmpl +++ b/vegacapsule/node_set_templates/default/vega_validators.tmpl @@ -4,15 +4,15 @@ Enabled = true [API] - Port = 30{{.NodeNumber}}2 + Port = {{add 300 .NodeNumber}}2 [API.REST] - Port = 30{{.NodeNumber}}3 + Port = {{add 300 .NodeNumber}}3 [Blockchain] [Blockchain.Tendermint] RPCAddr = "tcp://127.0.0.1:266{{.NodeNumber}}7" [Blockchain.Null] - Port = 31{{.NodeNumber}}1 + Port = {{add 310 .NodeNumber}}1 [EvtForward] Level = "Info"