- introduce variables to avoid publishing latest docker tags and installers - Refactor .goreleaser.yaml to simplify docker configurations and add environment-driven flags - removed management debug containers (it was doing only log var) - Stopped building arm v6 32bits in favor of v7 32 bits for services (not client) - Add target argument to docker files
21 lines
721 B
Docker
21 lines
721 B
Docker
FROM golang:1.25-alpine AS builder
|
|
WORKDIR /app
|
|
|
|
RUN echo "netbird:x:1000:1000:netbird:/var/lib/netbird:/sbin/nologin" > /tmp/passwd && \
|
|
echo "netbird:x:1000:netbird" > /tmp/group && \
|
|
mkdir -p /tmp/var/lib/netbird && \
|
|
mkdir -p /tmp/certs
|
|
|
|
FROM gcr.io/distroless/base:debug
|
|
ARG TARGETPLATFORM
|
|
COPY ${TARGETPLATFORM}/netbird-proxy /go/bin/netbird-proxy
|
|
COPY --from=builder /tmp/passwd /etc/passwd
|
|
COPY --from=builder /tmp/group /etc/group
|
|
COPY --from=builder --chown=1000:1000 /tmp/var/lib/netbird /var/lib/netbird
|
|
COPY --from=builder --chown=1000:1000 --chmod=755 /tmp/certs /certs
|
|
USER netbird:netbird
|
|
ENV HOME=/var/lib/netbird
|
|
ENV NB_PROXY_ADDRESS=":8443"
|
|
EXPOSE 8443
|
|
ENTRYPOINT ["/go/bin/netbird-proxy"]
|