diff --git a/Dockerfile.debug b/Dockerfile.debug index 715749d..953bb95 100644 --- a/Dockerfile.debug +++ b/Dockerfile.debug @@ -1,13 +1,14 @@ -FROM golang:alpine +FROM golang:latest RUN CGO_ENABLED=0 go install -ldflags "-s -w -extldflags '-static'" github.com/go-delve/delve/cmd/dlv@latest -# RUN CGO_ENABLED=0 go get -d github.com/gorilla/mux@latest + WORKDIR /app -EXPOSE 80 4000 +EXPOSE 10000 4000 COPY ./main/* ./ +RUN go get -d github.com/gorilla/mux@latest RUN go mod tidy -ENV GO111MODULE=off +# ENV GO111MODULE=off RUN CGO_ENABLED=0 go build -gcflags "all=-N -l" -o debug-app . CMD [ "/go/bin/dlv", "--listen=:4000", "--headless=true", "--log=true", "--accept-multiclient", "--api-version=2", "exec", "/app/debug-app" ]