-
Notifications
You must be signed in to change notification settings - Fork 20.8k
swarm/docker: add global-store and split docker images #19038
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,14 +10,23 @@ RUN mkdir -p $GOPATH/src/github.com/ethereum && \ | |
git checkout ${VERSION} && \ | ||
go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/swarm && \ | ||
go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/swarm/swarm-smoke && \ | ||
go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/geth && \ | ||
cp $GOPATH/bin/swarm /swarm && cp $GOPATH/bin/geth /geth && cp $GOPATH/bin/swarm-smoke /swarm-smoke | ||
go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/swarm/global-store && \ | ||
go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/geth | ||
|
||
|
||
# Release image with the required binaries and scripts | ||
FROM alpine:3.8 | ||
FROM alpine:3.8 as swarm-smoke | ||
WORKDIR / | ||
COPY --from=builder /swarm /geth /swarm-smoke / | ||
ADD run.sh /run.sh | ||
COPY --from=builder /go/bin/swarm-smoke / | ||
ADD run-smoke.sh /run-smoke.sh | ||
ENTRYPOINT ["/run-smoke.sh"] | ||
|
||
FROM alpine:3.8 as swarm-global-store | ||
WORKDIR / | ||
COPY --from=builder /go/bin/global-store / | ||
ENTRYPOINT ["/global-store"] | ||
|
||
FROM alpine:3.8 as swarm | ||
WORKDIR / | ||
COPY --from=builder /go/bin/swarm /go/bin/geth / | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, I guess those There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Almost correct. This COPY was already there before, it was just copying from |
||
ADD run.sh /run.sh | ||
ENTRYPOINT ["/run.sh"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure I understand what's being changed here.
The previous code was doing a
cp
ofswarm
andgeth
to/
- why is that not needed anymore? I remember that the image was relying somehow on this...