mirror of
https://github.com/tornadocash/rpc-nodes
synced 2024-02-02 14:53:56 +01:00
added files to run without a proxy
This commit is contained in:
parent
e39cd230ac
commit
958c7e61c9
@ -1,6 +1,6 @@
|
||||
# rpc-nodes
|
||||
|
||||
## 1. Start proxy (traefik)
|
||||
## 1. Start traefik proxy (you can skip this step if you are not going to use traefik)
|
||||
Create a shared network for running containers:
|
||||
```bash
|
||||
docker network create rpc-shared-network
|
||||
|
@ -14,14 +14,14 @@ You can also set a list of allowed IP addresses there and addresses to treat as
|
||||
mv example.env .env
|
||||
```
|
||||
|
||||
Start node:
|
||||
Start node (If you do not use traefik, specify the compose file with the `-f docker-compose.no-proxy.yml`):
|
||||
```bash
|
||||
docker-compose build
|
||||
docker-compose up -d rabbitmq heimdalld heimdallr bor
|
||||
```
|
||||
|
||||
## Upgrade
|
||||
Periodically check for new versions. if there is a release, then you need to update the tag in the environment file.
|
||||
Periodically check for new versions. if there is a release, then you need to update the tag (`BOR_TAG`) in the environment file.
|
||||
```bash
|
||||
docker-compose build
|
||||
docker-compose pull
|
||||
|
156
bor/docker-compose.no-proxy.yml
Normal file
156
bor/docker-compose.no-proxy.yml
Normal file
@ -0,0 +1,156 @@
|
||||
version: "3.7"
|
||||
|
||||
services:
|
||||
rabbitmq:
|
||||
image: rabbitmq:3-alpine
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
expose:
|
||||
- "5672/tcp"
|
||||
|
||||
heimdalld:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile.heimdall
|
||||
args:
|
||||
- DOCKER_TAG=${HEIMDALL_TAG}
|
||||
image: heimdall:local
|
||||
user: root
|
||||
environment:
|
||||
- HEIMDALL_CHAIN_ID=${HEIMDALL_CHAIN_ID}
|
||||
- HEIMDALL_SNAPSHOT_FILE=${HEIMDALL_SNAPSHOT_FILE}
|
||||
- HEIMDALL_GENESIS_URL=${HEIMDALL_GENESIS_URL}
|
||||
- HEIMDALL_SEEDS=${HEIMDALL_SEEDS}
|
||||
- HEIMDALL_BOR_RPC_URL=${HEIMDALL_BOR_RPC_URL}
|
||||
- HEIMDALL_ETH_RPC_URL=${HEIMDALL_ETH_RPC_URL}
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 2m
|
||||
depends_on:
|
||||
- rabbitmq
|
||||
entrypoint:
|
||||
- docker-entrypoint.sh
|
||||
- heimdalld
|
||||
- --home
|
||||
- /var/lib/heimdall
|
||||
- start
|
||||
volumes:
|
||||
- ./heimdall-data:/var/lib/heimdall
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
expose:
|
||||
- "26657/tcp"
|
||||
ports:
|
||||
- "26656:26656"
|
||||
|
||||
heimdallr:
|
||||
image: heimdall:local
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 2m
|
||||
depends_on:
|
||||
- heimdalld
|
||||
volumes:
|
||||
- ./heimdall-data:/var/lib/heimdall
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
expose:
|
||||
- "1317/tcp"
|
||||
user: root
|
||||
entrypoint:
|
||||
- heimdalld
|
||||
- --home
|
||||
- /var/lib/heimdall
|
||||
- rest-server
|
||||
- --chain-id=137
|
||||
- --laddr=tcp://0.0.0.0:1317
|
||||
- --node=tcp://heimdalld:26657
|
||||
|
||||
prune-bor:
|
||||
image: bor:local
|
||||
restart: "no"
|
||||
stop_grace_period: 3m
|
||||
user: root
|
||||
volumes:
|
||||
- ./bor-data:/var/lib/bor
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
entrypoint:
|
||||
- bor
|
||||
- --datadir
|
||||
- /var/lib/bor/data
|
||||
- snapshot
|
||||
- prune-state
|
||||
|
||||
bor:
|
||||
image: bor:local
|
||||
build:
|
||||
context: .
|
||||
dockerfile: ${BOR_DOCKER_FILE}
|
||||
args:
|
||||
- BUILD_TARGET=${BOR_SRC_TAG}
|
||||
- DOCKER_TAG=${BOR_TAG}
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 7m
|
||||
user: root
|
||||
environment:
|
||||
- BOR_DIR=/var/lib/bor
|
||||
- BOR_SETUP=${BOR_SETUP}
|
||||
- BOR_GENESIS=${BOR_GENESIS}
|
||||
- BOR_ARCHIVE_NODE_SNAPSHOT_FILE=${BOR_ARCHIVE_NODE_SNAPSHOT_FILE}
|
||||
- BOR_FULL_NODE_SNAPSHOT_FILE=${BOR_FULL_NODE_SNAPSHOT_FILE}
|
||||
- BOR_MODE=${BOR_MODE}
|
||||
entrypoint:
|
||||
- docker-entrypoint.sh
|
||||
- bor
|
||||
- --datadir
|
||||
- /var/lib/bor/data
|
||||
- --cache
|
||||
- ${BOR_CACHE}
|
||||
- --snapshot=false
|
||||
- --gcmode
|
||||
- ${BOR_MODE}
|
||||
- --ws
|
||||
- --ws.port
|
||||
- ${BOR_WS_PORT}
|
||||
- --ws.addr
|
||||
- 0.0.0.0
|
||||
- --ws.origins=*
|
||||
- --port
|
||||
- ${BOR_P2P_PORT}
|
||||
- --txpool.locals
|
||||
- ${TX_LOCAL_ADDR}
|
||||
- --txpool.globalslots
|
||||
- "100000"
|
||||
- --rpc.txfeecap
|
||||
- "0"
|
||||
- --txpool.accountslots
|
||||
- "256"
|
||||
- --bor.heimdall
|
||||
- http://heimdallr:1317
|
||||
- --bootnodes
|
||||
- "${BOR_BOOTNODES}"
|
||||
- --syncmode
|
||||
- "full"
|
||||
- --txpool.accountqueue
|
||||
- "64"
|
||||
- --txpool.globalqueue
|
||||
- "131072"
|
||||
- --maxpeers
|
||||
- "150"
|
||||
- --http
|
||||
- --http.addr
|
||||
- 0.0.0.0
|
||||
- --http.vhosts=*
|
||||
- --http.api
|
||||
- eth,net,web3,txpool,bor
|
||||
- --http.port
|
||||
- ${BOR_RPC_PORT}
|
||||
- --networkid
|
||||
- ${BOR_CHAIN_ID}
|
||||
- --ethstats
|
||||
- ${BOR_NODE_ID}:mainnet@bor-mainnet.vitwit.com:3000
|
||||
volumes:
|
||||
- ./bor-data:/var/lib/bor
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- ${BOR_RPC_PORT}:${BOR_RPC_PORT}/tcp
|
||||
- ${BOR_WS_PORT}:${BOR_WS_PORT}/tcp
|
||||
- ${BOR_P2P_PORT}:${BOR_P2P_PORT}/tcp
|
||||
- ${BOR_P2P_PORT}:${BOR_P2P_PORT}/udp
|
@ -1,4 +1,4 @@
|
||||
# Traefik
|
||||
# Traefik (if you use proxy)
|
||||
DOMAIN=domain.org
|
||||
# Comma-separated list of IP/mask addresses to allow access. Replace 0.0.0.0/0 with your address
|
||||
ALLOW_FROM=0.0.0.0/0
|
||||
|
@ -14,14 +14,14 @@ You can also set a list of allowed IP addresses there and addresses to treat as
|
||||
mv example.env .env
|
||||
```
|
||||
|
||||
Start node:
|
||||
Start node (If you do not use traefik, specify the compose file with the `-f docker-compose.no-proxy.yml`):
|
||||
```bash
|
||||
docker-compose build
|
||||
docker-compose up -d bsc
|
||||
```
|
||||
|
||||
## Upgrade
|
||||
Periodically check for new versions. if there is a release, then you need to update the tag in the environment file.
|
||||
Periodically check for new versions. If there is a release, then you need to update the tag (`BSC_TAG`) in the environment file.
|
||||
```bash
|
||||
docker-compose build
|
||||
docker-compose up -d bsc
|
||||
|
66
bsc/docker-compose.no-proxy.yml
Normal file
66
bsc/docker-compose.no-proxy.yml
Normal file
@ -0,0 +1,66 @@
|
||||
version: "3.7"
|
||||
|
||||
services:
|
||||
bsc-pruning:
|
||||
image: bsc:local
|
||||
container_name: bsc-pruning
|
||||
entrypoint:
|
||||
- bsc
|
||||
- snapshot
|
||||
- prune-state
|
||||
restart: "no"
|
||||
volumes:
|
||||
- ./bsc-data:/root/.ethereum
|
||||
- ./config.toml:/root/.ethereum/config.toml
|
||||
|
||||
bsc:
|
||||
image: bsc:local
|
||||
build:
|
||||
context: .
|
||||
args:
|
||||
- BSC_TAG=${BSC_TAG}
|
||||
container_name: bsc
|
||||
env_file: .env
|
||||
entrypoint:
|
||||
- docker-entrypoint.sh
|
||||
- bsc
|
||||
- --config
|
||||
- "/root/.ethereum/config.toml"
|
||||
- --port
|
||||
- "${P2P_PORT}"
|
||||
- --rpc.allow-unprotected-txs
|
||||
- --http
|
||||
- --http.addr
|
||||
- "0.0.0.0"
|
||||
- --http.port
|
||||
- "${HTTP_PORT}"
|
||||
- --http.corsdomain=*
|
||||
- --http.vhosts=*
|
||||
- --http.api
|
||||
- "eth,net,web3,parlia,txpool"
|
||||
- --ws
|
||||
- --ws.addr
|
||||
- "0.0.0.0"
|
||||
- --ws.port
|
||||
- "${WS_PORT}"
|
||||
- --ws.origins=*
|
||||
- --ws.api
|
||||
- "eth,net,web3,txpool"
|
||||
- --txpool.pricelimit
|
||||
- "1"
|
||||
- --txpool.reannouncetime
|
||||
- "1m"
|
||||
- --txpool.locals
|
||||
- "${TX_LOCAL_ADDR}"
|
||||
- --cache
|
||||
- "20480"
|
||||
restart: always
|
||||
stop_grace_period: 4m
|
||||
stop_signal: SIGINT
|
||||
ports:
|
||||
- ${HTTP_PORT}:${HTTP_PORT}
|
||||
- ${WS_PORT}:${WS_PORT}
|
||||
- ${P2P_PORT}:${P2P_PORT}
|
||||
volumes:
|
||||
- ./bsc-data:/root/.ethereum
|
||||
- ./config.toml:/root/.ethereum/config.toml
|
@ -1,4 +1,4 @@
|
||||
# Traefik
|
||||
# Traefik (if you use proxy)
|
||||
DOMAIN=domain.org
|
||||
# Comma-separated list of IP/mask addresses to allow access. Replace 0.0.0.0/0 with your address
|
||||
ALLOW_FROM=0.0.0.0/0
|
||||
|
69
geth/docker-compose.no-proxy.yml
Normal file
69
geth/docker-compose.no-proxy.yml
Normal file
@ -0,0 +1,69 @@
|
||||
version: "3.7"
|
||||
|
||||
services:
|
||||
geth-pruning:
|
||||
image: ethereum/client-go:stable
|
||||
container_name: geth-pruning
|
||||
restart: "no"
|
||||
env_file: .env
|
||||
command: "snapshot prune-state"
|
||||
volumes:
|
||||
- ./geth-data:/root/.ethereum
|
||||
geth:
|
||||
image: ethereum/client-go:stable
|
||||
container_name: geth
|
||||
restart: always
|
||||
env_file: .env
|
||||
command:
|
||||
- --maxpeers
|
||||
- "50"
|
||||
- --cache
|
||||
- "10629"
|
||||
- --port
|
||||
- "${P2P_PORT}"
|
||||
- --nat
|
||||
- "any"
|
||||
- --http
|
||||
- --http.addr
|
||||
- "0.0.0.0"
|
||||
- --http.port
|
||||
- "${HTTP_PORT}"
|
||||
- --http.corsdomain=*
|
||||
- --http.vhosts=*
|
||||
- --http.api
|
||||
- "eth,net,web3,txpool"
|
||||
- --ws
|
||||
- --ws.addr
|
||||
- "0.0.0.0"
|
||||
- --ws.port
|
||||
- "${WS_PORT}"
|
||||
- --ws.origins=*
|
||||
- --ws.api
|
||||
- "eth,net,web3,txpool"
|
||||
- --txpool.locals
|
||||
- "${TX_LOCAL_ADDR}"
|
||||
- --txpool.accountslots
|
||||
- "32"
|
||||
- --txpool.globalslots
|
||||
- "8192"
|
||||
- --txpool.accountqueue
|
||||
- "128"
|
||||
- --txpool.globalqueue
|
||||
- "2048"
|
||||
- --rpc.gascap
|
||||
- "0"
|
||||
- --rpc.txfeecap
|
||||
- "0"
|
||||
ports:
|
||||
- ${HTTP_PORT}:${HTTP_PORT}
|
||||
- ${WS_PORT}:${WS_PORT}
|
||||
- ${P2P_PORT}:${P2P_PORT}
|
||||
volumes:
|
||||
- ./geth-data:/root/.ethereum
|
||||
stop_grace_period: 3m30s
|
||||
stop_signal: SIGINT
|
||||
healthcheck:
|
||||
test: wget -nv -t1 --spider 'http://127.0.0.1:${HTTP_PORT}/' || exit 1
|
||||
interval: 5s
|
||||
timeout: 10s
|
||||
retries: 3
|
@ -1,4 +1,4 @@
|
||||
# Traefik
|
||||
# Traefik (if you use proxy)
|
||||
DOMAIN=domain.org
|
||||
# Comma-separated list of IP/mask addresses to allow access. Replace 0.0.0.0/0 with your address
|
||||
ALLOW_FROM=0.0.0.0/0
|
||||
|
@ -10,7 +10,7 @@ Set the domain name to be used in the `.env` file. You can also set a list of al
|
||||
mv example.env .env
|
||||
```
|
||||
|
||||
Start node:
|
||||
Start node (If you do not use traefik, specify the compose file with the `-f docker-compose.no-proxy.yml`):
|
||||
```bash
|
||||
docker-compose up -d geth
|
||||
```
|
||||
|
48
nethermind/docker-compose.no-proxy.yml
Normal file
48
nethermind/docker-compose.no-proxy.yml
Normal file
@ -0,0 +1,48 @@
|
||||
version: "3.7"
|
||||
services:
|
||||
nethermind:
|
||||
image: nethermind/nethermind:latest
|
||||
container_name: nethermind
|
||||
restart: always
|
||||
env_file: .env
|
||||
stop_grace_period: 2m
|
||||
ports:
|
||||
- ${HTTP_PORT}:${HTTP_PORT}
|
||||
- ${WS_PORT}:${WS_PORT}
|
||||
- ${P2P_PORT}:${P2P_PORT}/tcp
|
||||
- ${P2P_PORT}:${P2P_PORT}/udp
|
||||
command:
|
||||
- --datadir
|
||||
- /var/lib/nethermind
|
||||
- --Init.WebSocketsEnabled
|
||||
- "true"
|
||||
- --Network.DiscoveryPort
|
||||
- "${P2P_PORT}"
|
||||
- --Network.P2PPort
|
||||
- "${P2P_PORT}"
|
||||
- --JsonRpc.Enabled
|
||||
- "true"
|
||||
- --JsonRpc.EnabledModules
|
||||
- "Web3,Eth,Subscribe,Net,Parity"
|
||||
- --JsonRpc.Host
|
||||
- "0.0.0.0"
|
||||
- --JsonRpc.Port
|
||||
- "${HTTP_PORT}"
|
||||
- --JsonRpc.WebSocketsPort
|
||||
- "${WS_PORT}"
|
||||
- --Sync.FastSync
|
||||
- "true"
|
||||
- --config
|
||||
- xdai
|
||||
- --Pruning.Enabled
|
||||
- "true"
|
||||
- --Pruning.CacheMb
|
||||
- "4096"
|
||||
- --TxPool.Size
|
||||
- "4096"
|
||||
- --Sync.AncientBodiesBarrier
|
||||
- "1"
|
||||
- --Sync.AncientReceiptsBarrier
|
||||
- "1"
|
||||
volumes:
|
||||
- ./nethermind-data:/var/lib/nethermind
|
@ -1,4 +1,4 @@
|
||||
# Traefik
|
||||
# Traefik (if you use proxy)
|
||||
DOMAIN=domain.org
|
||||
# Comma-separated list of IP/mask addresses to allow access. Replace 0.0.0.0/0 with your address
|
||||
ALLOW_FROM=0.0.0.0/0
|
||||
|
@ -10,7 +10,7 @@ Set the domain name to be used in the `.env` file. You can also set a list of al
|
||||
mv example.env .env
|
||||
```
|
||||
|
||||
Start node:
|
||||
Start node (If you do not use traefik, specify the compose file with the `-f docker-compose.no-proxy.yml`):
|
||||
```bash
|
||||
docker-compose up -d
|
||||
```
|
||||
|
Loading…
Reference in New Issue
Block a user