-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
32 lines (24 loc) · 778 Bytes
/
Dockerfile
File metadata and controls
32 lines (24 loc) · 778 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# BUILDER
FROM golang:1.21.4-bullseye as builder
WORKDIR /workspace
COPY go.mod go.mod
COPY go.sum go.sum
RUN go mod download
COPY Makefile Makefile
COPY src/ src/
RUN make build
ENV TINI_VERSION v0.19.0
ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini-static /tini
RUN chmod +x /tini
# hadolint ignore=DL3008
RUN apt-get update && \
apt-get -y --no-install-recommends install ca-certificates && \
update-ca-certificates
# RUNTIME
FROM gcr.io/distroless/static-debian11:nonroot
LABEL org.opencontainers.image.source="https://github.com/XenitAB/azcagit"
WORKDIR /
COPY --from=builder /workspace/bin/azcagit /azcagit
COPY --from=builder /tini /tini
COPY --from=builder /etc/ssl/certs /etc/ssl/certs
ENTRYPOINT [ "/tini", "--", "/azcagit"]