Skip to content

Instantly share code, notes, and snippets.

@therealmitchconnors
Created April 17, 2020 05:13
Show Gist options
  • Save therealmitchconnors/9798fac83256bc68d387703a61de72c0 to your computer and use it in GitHub Desktop.
Save therealmitchconnors/9798fac83256bc68d387703a61de72c0 to your computer and use it in GitHub Desktop.
Debug image for pilot, adaptable to pretty much any distroless go debugging
FROM golang:latest AS getter
RUN go get -u -v github.com/go-delve/delve/cmd/dlv
#COPY dlv .
FROM docker.io/therealmitchconnors/pilot:therealmitchconnors
EXPOSE 40000
COPY --from=0 /go/bin/dlv .
ENTRYPOINT ["./dlv", "--listen=:40000", "--headless=true", "--api-version=2", "exec", "/usr/local/bin/pilot-discovery", "--"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment