Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support multi-arch #10

Merged
merged 2 commits into from
Sep 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 10 additions & 7 deletions build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
# Build Geth in a stock Go builder container
FROM golang:1.14-alpine as builder

ARG UPSTREAM_VERSION
FROM ethereum/client-go:${UPSTREAM_VERSION} as geth

# Pull Parity into a second stage deploy alpine container
RUN apk add --no-cache make gcc musl-dev linux-headers git && \
git clone -b ${UPSTREAM_VERSION} https://github.com/ethereum/go-ethereum.git && \
cd go-ethereum && make geth


FROM alpine:edge

RUN apk --no-cache add \
libstdc++ \
eudev-libs \
libgcc \
bash
libstdc++ eudev-libs libgcc bash

COPY --from=geth /usr/local/bin/geth /usr/local/bin/geth
COPY --from=builder /go/go-ethereum/build/bin/geth /usr/local/bin

ENV SYNCMODE fast
ENTRYPOINT geth --rpc --rpcaddr 0.0.0.0 --rpccorsdomain "*" --rpcvhosts "*" --ws --wsorigins "*" --wsaddr 0.0.0.0 --syncmode ${SYNCMODE:-fast} --nousb $EXTRA_OPTS
1 change: 1 addition & 0 deletions dappnode_package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"shortDescription": "Geth is the official Go implementation of the Ethereum protocol.",
"description": "Ethereum is a global, open-source platform for decentralized applications where you can write code that controls digital value, runs exactly as programmed, and is accessible anywhere in the world.",
"type": "library",
"architectures": ["linux/amd64", "linux/arm64"],
"chain": "ethereum",
"author": "DAppNode Association <[email protected]> (https://github.com/dappnode)",
"contributors": [
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ services:
build:
context: ./build
args:
- UPSTREAM_VERSION
UPSTREAM_VERSION: v1.9.21
volumes:
- 'geth:/root/.ethereum'
environment:
Expand Down