update ports from 466* to 266* (#104)
* updates ports from 466* to 266* * missed a port
This commit is contained in:
parent
a12785aa60
commit
47256cfda2
|
@ -57,7 +57,7 @@ finally, use our `Rest API <../specification/rpc.html>`__ to fetch the status of
|
|||
Note we are using ``kubectl exec`` because pods are not exposed (and should not be) to the
|
||||
outer network:
|
||||
|
||||
``kubectl exec -c tm tm-0 -- curl -s http://tm-1.basecoin:46657/status | json_pp``
|
||||
``kubectl exec -c tm tm-0 -- curl -s http://tm-1.basecoin:26657/status | json_pp``
|
||||
|
||||
**Using the dashboard:**
|
||||
|
||||
|
@ -223,7 +223,7 @@ Status of the second pod's Tendermint app:
|
|||
|
||||
::
|
||||
|
||||
kubectl exec -c tm tm-0 -- curl -s http://tm-1.<YOUR_APP_NAME>:46657/status | json_pp
|
||||
kubectl exec -c tm tm-0 -- curl -s http://tm-1.<YOUR_APP_NAME>:26657/status | json_pp
|
||||
|
||||
Security
|
||||
--------
|
||||
|
|
|
@ -9,9 +9,9 @@ metadata:
|
|||
app: YOUR_APP_NAME
|
||||
spec:
|
||||
ports:
|
||||
- port: 46656
|
||||
- port: 26656
|
||||
name: p2p
|
||||
- port: 46657
|
||||
- port: 26657
|
||||
name: rpc
|
||||
clusterIP: None
|
||||
selector:
|
||||
|
@ -91,9 +91,9 @@ spec:
|
|||
cpu: 100m
|
||||
memory: 256Mi
|
||||
ports:
|
||||
- containerPort: 46656
|
||||
- containerPort: 26656
|
||||
name: p2p
|
||||
- containerPort: 46657
|
||||
- containerPort: 26657
|
||||
name: rpc
|
||||
env:
|
||||
- name: SEEDS
|
||||
|
@ -148,7 +148,7 @@ spec:
|
|||
IFS=',' read -ra SEEDS_ARR <<< "$SEEDS"
|
||||
seeds=()
|
||||
for s in "${SEEDS_ARR[@]}"; do
|
||||
seeds+=("$s.$fqdn_suffix:46656")
|
||||
seeds+=("$s.$fqdn_suffix:26656")
|
||||
done
|
||||
seeds=$(IFS=','; echo "${seeds[*]}")
|
||||
|
||||
|
|
|
@ -9,9 +9,9 @@ metadata:
|
|||
app: basecoin
|
||||
spec:
|
||||
ports:
|
||||
- port: 46656
|
||||
- port: 26656
|
||||
name: p2p
|
||||
- port: 46657
|
||||
- port: 26657
|
||||
name: rpc
|
||||
clusterIP: None
|
||||
selector:
|
||||
|
@ -150,9 +150,9 @@ spec:
|
|||
imagePullPolicy: IfNotPresent
|
||||
image: tendermint/tendermint:0.10.0
|
||||
ports:
|
||||
- containerPort: 46656
|
||||
- containerPort: 26656
|
||||
name: p2p
|
||||
- containerPort: 46657
|
||||
- containerPort: 26657
|
||||
name: rpc
|
||||
env:
|
||||
- name: SEEDS
|
||||
|
@ -207,7 +207,7 @@ spec:
|
|||
IFS=',' read -ra SEEDS_ARR <<< "$SEEDS"
|
||||
seeds=()
|
||||
for s in "${SEEDS_ARR[@]}"; do
|
||||
seeds+=("$s.$fqdn_suffix:46656")
|
||||
seeds+=("$s.$fqdn_suffix:26656")
|
||||
done
|
||||
seeds=$(IFS=','; echo "${seeds[*]}")
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@ with a bit of cash....
|
|||
|
||||
### Tendermint Chain ID
|
||||
|
||||
`kubectl exec -c tm tm-0 -- curl -s http://tm-1.basecoin:46657/status | json_pp | grep network`
|
||||
`kubectl exec -c tm tm-0 -- curl -s http://tm-1.basecoin:26657/status | json_pp | grep network`
|
||||
|
||||
set TM_CHAIN with the value there
|
||||
|
||||
|
@ -29,13 +29,13 @@ set BC_CHAIN with the value there
|
|||
|
||||
We need to be able to reach the tendermint rpc interface from our shell.
|
||||
|
||||
`kubectl port-forward tm-0 46657:46657`
|
||||
`kubectl port-forward tm-0 26657:26657`
|
||||
|
||||
### Start basecoin-proxy
|
||||
|
||||
Using this info, let's connect our proxy and get going
|
||||
|
||||
`proxy-basecoin -tmchain=$TM_CHAIN -chain=$BC_CHAIN -rpc=localhost:46657`
|
||||
`proxy-basecoin -tmchain=$TM_CHAIN -chain=$BC_CHAIN -rpc=localhost:26657`
|
||||
|
||||
## Basecoin accounts
|
||||
|
||||
|
|
|
@ -9,9 +9,9 @@ metadata:
|
|||
app: counter
|
||||
spec:
|
||||
ports:
|
||||
- port: 46656
|
||||
- port: 26656
|
||||
name: p2p
|
||||
- port: 46657
|
||||
- port: 26657
|
||||
name: rpc
|
||||
clusterIP: None
|
||||
selector:
|
||||
|
@ -83,9 +83,9 @@ spec:
|
|||
imagePullPolicy: IfNotPresent
|
||||
image: tendermint/tendermint:0.10.0
|
||||
ports:
|
||||
- containerPort: 46656
|
||||
- containerPort: 26656
|
||||
name: p2p
|
||||
- containerPort: 46657
|
||||
- containerPort: 26657
|
||||
name: rpc
|
||||
env:
|
||||
- name: SEEDS
|
||||
|
@ -140,7 +140,7 @@ spec:
|
|||
IFS=',' read -ra SEEDS_ARR <<< "$SEEDS"
|
||||
seeds=()
|
||||
for s in "${SEEDS_ARR[@]}"; do
|
||||
seeds+=("$s.$fqdn_suffix:46656")
|
||||
seeds+=("$s.$fqdn_suffix:26656")
|
||||
done
|
||||
seeds=$(IFS=','; echo "${seeds[*]}")
|
||||
|
||||
|
|
|
@ -9,9 +9,9 @@ metadata:
|
|||
app: dummy
|
||||
spec:
|
||||
ports:
|
||||
- port: 46656
|
||||
- port: 26656
|
||||
name: p2p
|
||||
- port: 46657
|
||||
- port: 26657
|
||||
name: rpc
|
||||
clusterIP: None
|
||||
selector:
|
||||
|
@ -83,9 +83,9 @@ spec:
|
|||
imagePullPolicy: IfNotPresent
|
||||
image: tendermint/tendermint:0.10.0
|
||||
ports:
|
||||
- containerPort: 46656
|
||||
- containerPort: 26656
|
||||
name: p2p
|
||||
- containerPort: 46657
|
||||
- containerPort: 26657
|
||||
name: rpc
|
||||
env:
|
||||
- name: SEEDS
|
||||
|
@ -140,7 +140,7 @@ spec:
|
|||
IFS=',' read -ra SEEDS_ARR <<< "$SEEDS"
|
||||
seeds=()
|
||||
for s in "${SEEDS_ARR[@]}"; do
|
||||
seeds+=("$s.$fqdn_suffix:46656")
|
||||
seeds+=("$s.$fqdn_suffix:26656")
|
||||
done
|
||||
seeds=$(IFS=','; echo "${seeds[*]}")
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ spec:
|
|||
containers:
|
||||
- name: monitor
|
||||
image: tendermint/monitor
|
||||
args: ["-listen-addr=tcp://0.0.0.0:46670", "tm-0.dummy:46657,tm-1.dummy:46657,tm-2.dummy:46657,tm-3.dummy:46657"]
|
||||
args: ["-listen-addr=tcp://0.0.0.0:26670", "tm-0.dummy:26657,tm-1.dummy:26657,tm-2.dummy:26657,tm-3.dummy:26657"]
|
||||
ports:
|
||||
- containerPort: 46670
|
||||
- containerPort: 26670
|
||||
name: rpc
|
||||
|
|
|
@ -14,6 +14,6 @@ spec:
|
|||
set -ex
|
||||
while true
|
||||
do
|
||||
./transact 100 "tm-0.dummy:46657"
|
||||
./transact 100 "tm-0.dummy:26657"
|
||||
sleep 1
|
||||
done
|
||||
|
|
|
@ -6,7 +6,7 @@ Tendermint blockchain benchmarking tool:
|
|||
|
||||
For example, the following:
|
||||
|
||||
tm-bench -T 10 -r 1000 localhost:46657
|
||||
tm-bench -T 10 -r 1000 localhost:26657
|
||||
|
||||
will output:
|
||||
|
||||
|
@ -24,7 +24,7 @@ then run:
|
|||
tendermint init
|
||||
tendermint node --proxy_app=kvstore
|
||||
|
||||
tm-bench localhost:46657
|
||||
tm-bench localhost:26657
|
||||
|
||||
with the last command being in a seperate window.
|
||||
|
||||
|
@ -33,7 +33,7 @@ with the last command being in a seperate window.
|
|||
tm-bench [-c 1] [-T 10] [-r 1000] [endpoints]
|
||||
|
||||
Examples:
|
||||
tm-bench localhost:46657
|
||||
tm-bench localhost:26657
|
||||
Flags:
|
||||
-T int
|
||||
Exit after the specified amount of time in seconds (default 10)
|
||||
|
|
|
@ -45,7 +45,7 @@ Usage:
|
|||
tm-bench [-c 1] [-T 10] [-r 1000] [endpoints] [-output-format <plain|json> [-broadcast-tx-method <async|sync|commit>]]
|
||||
|
||||
Examples:
|
||||
tm-bench localhost:46657`)
|
||||
tm-bench localhost:26657`)
|
||||
fmt.Println("Flags:")
|
||||
flag.PrintDefaults()
|
||||
}
|
||||
|
|
|
@ -13,17 +13,17 @@ Assuming your application is running in another container with the name
|
|||
`app`:
|
||||
|
||||
docker run -it --rm -v "/tmp:/tendermint" tendermint/tendermint init
|
||||
docker run -it --rm -v "/tmp:/tendermint" -p "46657:46657" --name=tm --link=app tendermint/tendermint node --proxy_app=tcp://app:46658
|
||||
docker run -it --rm -v "/tmp:/tendermint" -p "26657:26657" --name=tm --link=app tendermint/tendermint node --proxy_app=tcp://app:26658
|
||||
|
||||
docker run -it --rm -p "46670:46670" --link=tm tendermint/monitor tm:46657
|
||||
docker run -it --rm -p "26670:26670" --link=tm tendermint/monitor tm:26657
|
||||
|
||||
If you don't have an application yet, but still want to try monitor out,
|
||||
use `kvstore`:
|
||||
|
||||
docker run -it --rm -v "/tmp:/tendermint" tendermint/tendermint init
|
||||
docker run -it --rm -v "/tmp:/tendermint" -p "46657:46657" --name=tm tendermint/tendermint node --proxy_app=kvstore
|
||||
docker run -it --rm -v "/tmp:/tendermint" -p "26657:26657" --name=tm tendermint/tendermint node --proxy_app=kvstore
|
||||
|
||||
docker run -it --rm -p "46670:46670" --link=tm tendermint/monitor tm:46657
|
||||
docker run -it --rm -p "26670:26670" --link=tm tendermint/monitor tm:26657
|
||||
|
||||
### Using Binaries
|
||||
|
||||
|
@ -34,37 +34,37 @@ then run:
|
|||
tendermint init
|
||||
tendermint node --proxy_app=kvstore
|
||||
|
||||
tm-monitor localhost:46657
|
||||
tm-monitor localhost:26657
|
||||
|
||||
with the last command being in a seperate window.
|
||||
|
||||
## Usage
|
||||
|
||||
tm-monitor [-v] [-no-ton] [-listen-addr="tcp://0.0.0.0:46670"] [endpoints]
|
||||
tm-monitor [-v] [-no-ton] [-listen-addr="tcp://0.0.0.0:26670"] [endpoints]
|
||||
|
||||
Examples:
|
||||
# monitor single instance
|
||||
tm-monitor localhost:46657
|
||||
tm-monitor localhost:26657
|
||||
|
||||
# monitor a few instances by providing comma-separated list of RPC endpoints
|
||||
tm-monitor host1:46657,host2:46657
|
||||
tm-monitor host1:26657,host2:26657
|
||||
Flags:
|
||||
-listen-addr string
|
||||
HTTP and Websocket server listen address (default "tcp://0.0.0.0:46670")
|
||||
HTTP and Websocket server listen address (default "tcp://0.0.0.0:26670")
|
||||
-no-ton
|
||||
Do not show ton (table of nodes)
|
||||
-v verbose logging
|
||||
|
||||
### RPC UI
|
||||
|
||||
Run `tm-monitor` and visit http://localhost:46670 You should see the
|
||||
Run `tm-monitor` and visit http://localhost:26670 You should see the
|
||||
list of the available RPC endpoints:
|
||||
|
||||
http://localhost:46670/status
|
||||
http://localhost:46670/status/network
|
||||
http://localhost:46670/monitor?endpoint=_
|
||||
http://localhost:46670/status/node?name=_
|
||||
http://localhost:46670/unmonitor?endpoint=_
|
||||
http://localhost:26670/status
|
||||
http://localhost:26670/status/network
|
||||
http://localhost:26670/monitor?endpoint=_
|
||||
http://localhost:26670/status/node?name=_
|
||||
http://localhost:26670/unmonitor?endpoint=_
|
||||
|
||||
The API is available as GET requests with URI encoded parameters, or as
|
||||
JSONRPC POST requests. The JSONRPC methods are also exposed over
|
||||
|
|
|
@ -19,7 +19,7 @@ func main() {
|
|||
var listenAddr string
|
||||
var noton bool
|
||||
|
||||
flag.StringVar(&listenAddr, "listen-addr", "tcp://0.0.0.0:46670", "HTTP and Websocket server listen address")
|
||||
flag.StringVar(&listenAddr, "listen-addr", "tcp://0.0.0.0:26670", "HTTP and Websocket server listen address")
|
||||
flag.BoolVar(¬on, "no-ton", false, "Do not show ton (table of nodes)")
|
||||
|
||||
flag.Usage = func() {
|
||||
|
@ -27,14 +27,14 @@ func main() {
|
|||
applications, collecting and providing various statistics to the user.
|
||||
|
||||
Usage:
|
||||
tm-monitor [-no-ton] [-listen-addr="tcp://0.0.0.0:46670"] [endpoints]
|
||||
tm-monitor [-no-ton] [-listen-addr="tcp://0.0.0.0:26670"] [endpoints]
|
||||
|
||||
Examples:
|
||||
# monitor single instance
|
||||
tm-monitor localhost:46657
|
||||
tm-monitor localhost:26657
|
||||
|
||||
# monitor a few instances by providing comma-separated list of RPC endpoints
|
||||
tm-monitor host1:46657,host2:46657`)
|
||||
tm-monitor host1:26657,host2:26657`)
|
||||
fmt.Println("Flags:")
|
||||
flag.PrintDefaults()
|
||||
}
|
||||
|
|
|
@ -67,6 +67,6 @@ func createValidatorNode(t *testing.T) (n *monitor.Node, emMock *mock.EventMeter
|
|||
rpcClientMock := &mock.RpcClient{Stubs: stubs}
|
||||
rpcClientMock.SetCodec(cdc)
|
||||
|
||||
n = monitor.NewNodeWithEventMeterAndRpcClient("tcp://127.0.0.1:46657", emMock, rpcClientMock)
|
||||
n = monitor.NewNodeWithEventMeterAndRpcClient("tcp://127.0.0.1:26657", emMock, rpcClientMock)
|
||||
return
|
||||
}
|
||||
|
|
|
@ -85,7 +85,7 @@ func startValidatorNode(t *testing.T) (n *monitor.Node, emMock *mock.EventMeter)
|
|||
rpcClientMock := &mock.RpcClient{Stubs: stubs}
|
||||
rpcClientMock.SetCodec(cdc)
|
||||
|
||||
n = monitor.NewNodeWithEventMeterAndRpcClient("tcp://127.0.0.1:46657", emMock, rpcClientMock)
|
||||
n = monitor.NewNodeWithEventMeterAndRpcClient("tcp://127.0.0.1:26657", emMock, rpcClientMock)
|
||||
|
||||
err := n.Start()
|
||||
require.Nil(t, err)
|
||||
|
|
|
@ -51,7 +51,7 @@ func broadcastTxsToHost(wg *sync.WaitGroup, errCh chan error, valI int, valHost
|
|||
reconnectSleepSeconds := time.Second * 1
|
||||
|
||||
// thisStart := time.Now()
|
||||
// cli := rpcclient.NewClientURI(valHost + ":46657")
|
||||
// cli := rpcclient.NewClientURI(valHost + ":26657")
|
||||
fmt.Println("Connecting to host to broadcast txs", valI, valHost)
|
||||
cli := rpcclient.NewWSClient(valHost, "/websocket")
|
||||
if _, err := cli.Start(); err != nil {
|
||||
|
|
Loading…
Reference in New Issue