LoginSignup
1
2

More than 5 years have passed since last update.

bootnode コマンドが入った Docker イメージを作成する

Posted at

geth の Docker イメージは ethereum/client-go から取得できるんですが geth コマンドしか入ってないので bootnode コマンドは使えません。
bootnode を使いたいときは go-ethereum のソースコードを Github から取得して自分でビルドしましょう。

Docker イメージのビルド

ethereum/go-ethereum: Official Go implementation of the Ethereum protocol

トップレベルディレクトリに Dockerfile が2つと containers/docker にもいくつか入っています。今回はトップレベルディレクトリにある Dockerfile.alltools を使います。

まずは Github から clone して ethereum/client-go-alltools という名称で Docker イメージを作成します。

$ git clone git@github.com:ethereum/go-ethereum.git
$ cd go-ethereum
$ docker build -f Dockerfile.alltools -t ethereum/client-go-alltools .

ビルドが終わったら bootnode を実行してみましょう。

$ docker run -t ethereum/client-go-alltools bootnode
Fatal: Use -nodekey or -nodekeyhex to specify a private key

bootnode コマンド入りのイメージが作成できました。

1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2