diff options
author | Alexander Karl <akarl@darknebu.la> | 2019-10-10 21:26:19 +0200 |
---|---|---|
committer | Alexander Karl <akarl@darknebu.la> | 2019-10-10 21:26:19 +0200 |
commit | b1600e8bc69e83b8240ec03dbbf20715f7ca2854 (patch) | |
tree | 3e9fe02afc2f997b67782200407bc72ceeee8161 | |
parent | f27bbac2e4cbdef61da2e6f85143f194b0654b1c (diff) |
Add Dockerfile
-rw-r--r-- | Dockerfile | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..c2d9f69 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM golang:1.13 as build-env + +WORKDIR /go/src/app +ADD . /go/src/app + +RUN go get -d -v ./... + +RUN go build -o /go/bin/static + +FROM alpine:stable +COPY --from=build-env /go/bin/static / + +ENV port=8080 +ENV directory="/mount" +ENV subpath="079521df-c66e-4c1e-86ce-daf0075cc73f" + +CMD /static -port ${port} -dir ${dir} -subpath ${subpath} \ No newline at end of file |