FROM golang:1-alpine AS build WORKDIR /go/src/git.woozle.org/neale/wallart-server COPY go.* cmd ./ RUN CGO_ENABLED=0 GOOS=linux go install ./... FROM alpine AS runtime WORKDIR /target RUN mkdir cache COPY web web COPY --from=build /go/bin/wallart-server . FROM scratch COPY --from=runtime /target / ENTRYPOINT ["/wallart-server"]