2019-05-06 00:56:27 +00:00
|
|
|
FROM golang:1.11.5 as build
|
|
|
|
WORKDIR /go/src/github.com/mitchell/selfpass
|
|
|
|
COPY . .
|
2019-05-30 06:32:56 +00:00
|
|
|
ENV GO111MODULE on
|
2019-05-06 00:56:27 +00:00
|
|
|
RUN make build
|
|
|
|
|
2019-05-28 01:16:50 +00:00
|
|
|
FROM debian:stable-20190506-slim
|
2019-05-30 06:32:56 +00:00
|
|
|
COPY --from=build /go/src/github.com/mitchell/selfpass/bin/server /usr/bin/server
|
|
|
|
RUN groupadd -r selfpass && useradd --no-log-init -r -g selfpass selfpass
|
|
|
|
USER selfpass
|
|
|
|
WORKDIR /home/selfpass
|
2019-05-22 15:22:40 +00:00
|
|
|
ENTRYPOINT ["server"]
|
2019-05-06 00:56:27 +00:00
|
|
|
EXPOSE 8080
|