Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
28 changed files
with
559 additions
and
89 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Dockerfile | ||
Dockerfile-* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
FROM golang:1.9-stretch AS builder | ||
MAINTAINER Hector Sanjuan <hector@protocol.ai> | ||
|
||
# This dockerfile builds cluster and runs it along with go-ipfs. | ||
# It re-uses the latest go-ipfs:release container. | ||
|
||
# This builder just builds the cluster binaries | ||
ENV GOPATH /go | ||
ENV SRC_PATH $GOPATH/src/github.com/ipfs/ipfs-cluster | ||
|
||
COPY . $SRC_PATH | ||
WORKDIR $SRC_PATH | ||
RUN make install | ||
|
||
#------------------------------------------------------ | ||
FROM ipfs/go-ipfs:release | ||
MAINTAINER Hector Sanjuan <hector@protocol.ai> | ||
|
||
# This is the container which just puts the previously | ||
# built binaries on the go-ipfs-container. | ||
|
||
ENV GOPATH /go | ||
ENV SRC_PATH /go/src/github.com/ipfs/ipfs-cluster | ||
ENV IPFS_CLUSTER_PATH /data/ipfs-cluster | ||
|
||
EXPOSE 9094 | ||
EXPOSE 9095 | ||
EXPOSE 9096 | ||
|
||
COPY --from=builder $GOPATH/bin/ipfs-cluster-service /usr/local/bin/ipfs-cluster-service | ||
COPY --from=builder $GOPATH/bin/ipfs-cluster-ctl /usr/local/bin/ipfs-cluster-ctl | ||
COPY --from=builder $SRC_PATH/docker/start-daemons.sh /usr/local/bin/start-daemons.sh | ||
|
||
RUN mkdir -p $IPFS_CLUSTER_PATH && \ | ||
chown 1000:100 $IPFS_CLUSTER_PATH | ||
|
||
VOLUME $IPFS_CLUSTER_PATH | ||
ENTRYPOINT ["/sbin/tini", "--", "/usr/local/bin/start-daemons.sh"] | ||
|
||
# Defaults for ipfs-cluster-service would go here | ||
CMD [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.