Переписал Dockerfile, теперь образы контейнеров весят меньше

This commit is contained in:
B4D_US3R 2026-01-01 21:24:40 +05:00
parent 4f998a2730
commit 9455220a0b
3 changed files with 13 additions and 2 deletions

View file

@ -1,4 +1,6 @@
FROM golang:1.24
FROM golang:1.24-alpine AS build
RUN apk add --no-cache make
WORKDIR /app/kiki
@ -14,4 +16,12 @@ COPY Makefile /app/kiki/
RUN make
FROM alpine:latest
WORKDIR /app/kiki/
COPY --from=build /app/kiki/kiki /app/kiki/kiki
RUN chmod +x /app/kiki/kiki
CMD [ "/app/kiki/kiki", "run" ]