nano-run/Dockerfile.build

13 lines
338 B
Docker
Raw Normal View History

2020-09-10 10:11:34 +00:00
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"]