Files
devops-directive-docker-course/11-development-workflow/api-golang/Dockerfile.dev
2023-02-13 09:55:19 -05:00

19 lines
364 B
Docker

# Using bullseye instead of alpine because debugger didnt work in alpine
FROM golang:1.19-bullseye
WORKDIR /app
# Install air for hot reload
RUN go install github.com/cosmtrek/air@latest
# Install delve for debugging
RUN go install github.com/go-delve/delve/cmd/dlv@latest
COPY go.mod go.sum ./
RUN go mod download
COPY . .
CMD ["air", "-c", ".air.toml"]