Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@xpepermint
Created December 31, 2018 12:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xpepermint/2ce1d9aaa134db8fed1b90c87292a373 to your computer and use it in GitHub Desktop.
Save xpepermint/2ce1d9aaa134db8fed1b90c87292a373 to your computer and use it in GitHub Desktop.
Geth setup with Docker
```
docker run -d \
--name geth-test \
-p 8545:8545 \
-v ~/.docker/machine/volumes/geth-test/data:/root/.ethereum \
ethereum/client-go \
--testnet \
--rpc \
--rpcaddr "0.0.0.0" \
--rpccorsdomain "*" \
--rpcapi "db,eth,net,web3,personal,web3" \
--cache=512
```
```
docker exec -it geth-test geth console --port 35555
```
```
curl -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"web3_clientVersion","params":[],"id":67}' http://localhost:8545
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment