Dockerfile 536 B

123456789101112131415161718192021222324
  1. # vim: se syn=dockerfile:
  2. FROM golang:1.13-alpine AS build
  3. ENV CGO_ENABLED 0
  4. RUN apk add --no-cache --update make git perl-utils dep shadow
  5. ENV PATH "/go/bin:${PATH}"
  6. RUN go get honnef.co/go/tools/cmd/staticcheck
  7. RUN mkdir -p /go/src/github.com/joyent/kosh
  8. WORKDIR /go/src/github.com/joyent/kosh
  9. COPY . /go/src/github.com/joyent/kosh/
  10. RUN make
  11. FROM scratch
  12. COPY --from=build /go/src/github.com/joyent/kosh/bin/kosh /bin/kosh
  13. COPY --from=build /etc/ssl /etc/ssl
  14. ENV KOSH_TOKEN "broken"
  15. ENTRYPOINT [ "/bin/kosh" ]
  16. CMD ["version"]