nano-run/Dockerfile.build
Alexander Baryshnikov 4edfaa4d26 initial code added
2020-09-10 18:11:34 +08:00

13 lines
338 B
Docker

FROM golang:1.15-alpine3.12 AS build
WORKDIR /go/src/app
COPY . .
RUN go get -d -v ./...
RUN go build -o nano-run -v ./cmd/nano-run/...
FROM alpine:3.12
VOLUME /data
VOLUME /conf.d
COPY docker/server.yaml /server.yaml
COPY --from=build /go/src/app/nano-run /bin/nano-run
CMD ["/bin/nano-run", "server", "run", "-f", "-c", "server.yaml"]