Skip to content

Commit

Permalink
Add the ability to share the eth1 node
Browse files Browse the repository at this point in the history
  • Loading branch information
yorickdowne committed Nov 11, 2020
1 parent cdd88aa commit 1992c7d
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 5 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ directory (`cd ~/eth2-docker` by default):
* !! If coming from Prysm alpha.29 or earlier, make changes as per notes for [v0.1.7](#v017-2020-10-15)
* `sudo docker-compose up -d eth2`

## v0.1.8.5 2020-11-11

* Added option to run eth1 node exposed to the host on RPC port

## v0.1.8.4 2020-11-08

* Updated grafana image to change all occurrences of `job="beacon"` to `jon=beacon_node` in the metanull dashboard.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# eth2-docker v0.1.8.2
# eth2-docker v0.1.8.5

Unofficial and experimental docker build instructions for eth2 clients

Expand Down
1 change: 1 addition & 0 deletions SETUP.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ openethereum with `:` between the file names.
- `nimbus-base.yml` - Nimbus
- `oe.yml` - local openethereum eth1 chain node
- `geth.yml` - local geth eth1 chain node
- `shared-eth1.yml` - makes the RPC port of the eth1 node available from the host, for using the eth1 node with other nodes or with Metamask. **Not encrypted**, do not expose to Internet.
- `prysm-slasher.yml` - Prysm experimental Slasher which helps secure the chain and may result in additional earnings. The experimental slasher can lead to missed attestations do to the additional resource demand.
- `lh-grafana.yml` - grafana dashboard for Lighthouse
- `prysm-grafana.yml` - grafana dashboard for Prysm. Not encrypted, do not expose to Internet.
Expand Down
8 changes: 7 additions & 1 deletion default.env
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,12 @@ NIM_PORT=9000
TEKU_PORT=9000
# Local grafana dashboard port. Do not expose to Internet, it is insecure http
GRAFANA_PORT=3000
# ETH1 RPC port, important when using shared-eth1.yml
ETH1_RPC_PORT=8545
# ETH1 RPC CORS open to all. Insecure but allows for easy testing
ETH1_RPC_CORS=all
# ETH1 RPC CORS, here for Metamask extension - was not functional in testing
#ETH1_RPC_CORS="chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn moz-extension://f3a66ea7-df4d-4731-80db-de45a4abebd6"

# These variables are not likely to require adjustment

Expand All @@ -59,7 +65,7 @@ PRYSM_USER=prysm
TEKU_BUILD_TARGET=$(git describe --tags $(git rev-list --tags --max-count=1))
TEKU_USER=teku

NIM_BUILD_TARGET=devel
NIM_BUILD_TARGET=$(git describe --tags $(git rev-list --tags --max-count=1))
NIM_USER=nimbus

DEPCLI_BUILD_TARGET=$(git describe --tags $(git rev-list --tags --max-count=1))
Expand Down
5 changes: 3 additions & 2 deletions geth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ services:
- ${ETH1_PORT}:${ETH1_PORT}/tcp
- ${ETH1_PORT}:${ETH1_PORT}/udp
expose:
- 8545
- 8546
- ${ETH1_RPC_PORT}/tcp
entrypoint:
- geth
- --nousb
Expand All @@ -32,6 +31,8 @@ services:
- /var/lib/goethereum
- --port
- ${ETH1_PORT}
- --rpcport
- ${ETH1_RPC_PORT}
command: ${GETH1_NETWORK}
beacon:
depends_on:
Expand Down
5 changes: 4 additions & 1 deletion oe.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ services:
- ${ETH1_PORT}:${ETH1_PORT}/tcp
- ${ETH1_PORT}:${ETH1_PORT}/udp
expose:
- 8545
- ${ETH1_RPC_PORT}/tcp
entrypoint:
- openethereum
- --no-ws
Expand All @@ -26,9 +26,12 @@ services:
- --jsonrpc-interface=all
- --jsonrpc-apis=net,eth
- --jsonrpc-hosts=all
- --jsonrpc-cors=${ETH1_RPC_CORS}
- --chain=${ETH1_NETWORK}
- --port
- ${ETH1_PORT}
- --jsonrpc-port
- ${ETH1_RPC_PORT}
beacon:
depends_on:
- eth1
Expand Down
6 changes: 6 additions & 0 deletions shared-eth1.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# To be used in conjunction with oe.yml, nm.yml or geth.yml
version: "3"
services:
eth1:
ports:
- ${ETH1_RPC_PORT}:${ETH1_RPC_PORT}/tcp

0 comments on commit 1992c7d

Please sign in to comment.