storj/cmd/gw/Dockerfile
Matt Robinson 026997e725
All-in-one docker-compose project (#267)
* First pass at an all-in-one compose project

* Sort out dependencies so uplink can build in docker

* Added the final bits to make this work

* Add readme for all-in-one

* Fix sed to work on OS X and Linux

* Make the readme for all-in-one better

* Only bring up the satellite and uplink after fixing the mock overlay

* Use a dummy value for mock overlay for now

* Finishing touches

* Fix url form for aws cli tool

* Move files out of all-in-one directory to help with directory confusion.

* Added a make target to make all-in-one even better
2018-08-23 11:48:03 -04:00

22 lines
500 B
Docker

# build
ARG GO_VERSION=1.10
FROM golang:${GO_VERSION}-alpine AS build-env
RUN apk add -U curl git musl-dev gcc
RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
WORKDIR /go/src/storj.io/storj
COPY . .
RUN dep ensure -vendor-only
RUN go build -o uplink cmd/gw/*.go
# final stage
FROM alpine
ENV API_KEY= \
SATELLITE_ADDR=
EXPOSE 7777
WORKDIR /app
COPY --from=build-env /go/src/storj.io/storj/uplink /app/
COPY cmd/gw/entrypoint /entrypoint
ENTRYPOINT ["/entrypoint"]