2023-12-28 13:22:16 -05:00
|
|
|
FROM golang:1.21.4 as build
|
2023-02-17 15:37:36 -05:00
|
|
|
|
2023-05-29 17:58:23 -04:00
|
|
|
LABEL author="vlbeaudoin"
|
2023-02-17 15:37:36 -05:00
|
|
|
|
|
|
|
WORKDIR /go/src/app
|
|
|
|
|
2023-05-29 17:58:23 -04:00
|
|
|
COPY go.mod go.sum main.go ./
|
2023-02-17 15:37:36 -05:00
|
|
|
|
2023-05-29 17:58:23 -04:00
|
|
|
ADD cmd/ cmd/
|
|
|
|
ADD data/ data/
|
|
|
|
ADD handlers/ handlers/
|
|
|
|
ADD models/ models/
|
2023-06-15 15:50:28 -04:00
|
|
|
ADD responses/ responses/
|
2024-09-16 14:42:32 -04:00
|
|
|
ADD sql/ sql/
|
2023-06-15 15:50:28 -04:00
|
|
|
ADD web/ web/
|
2023-02-17 15:37:36 -05:00
|
|
|
|
2024-09-16 14:36:51 -04:00
|
|
|
RUN CGO_ENABLED=0 go build -a -o bottin-agenda .
|
2023-02-17 15:37:36 -05:00
|
|
|
|
2023-05-29 17:58:23 -04:00
|
|
|
# Alpine
|
|
|
|
|
|
|
|
FROM alpine:latest
|
|
|
|
|
|
|
|
WORKDIR /app
|
|
|
|
|
|
|
|
COPY --from=build /go/src/app/bottin-agenda /usr/bin/bottin-agenda
|
|
|
|
|
|
|
|
CMD ["bottin-agenda", "--help"]
|