diff --git a/Dockerfile b/Dockerfile index 13652393..950c48b2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,7 +11,7 @@ FROM alpine:3.21.3 # add a c lib # set the working directory WORKDIR /root/ -RUN apk update && apk upgrade +RUN apk upgrade --no-cache RUN apk add --no-cache sqlite RUN mkdir -p /etc/netclient/config COPY --from=builder /app/netmaker . diff --git a/Dockerfile-quick b/Dockerfile-quick index f4b3eee9..f7cda278 100644 --- a/Dockerfile-quick +++ b/Dockerfile-quick @@ -6,7 +6,7 @@ COPY ./netmaker /root/netmaker ENV GO111MODULE=auto # add a c lib -RUN apk add gcompat iptables wireguard-tools +RUN apk add --no-cache gcompat iptables wireguard-tools # set the working directory WORKDIR /root/ RUN mkdir -p /etc/netclient/config diff --git a/docker/Dockerfile-go-builder b/docker/Dockerfile-go-builder index 982f1e6f..90f9a810 100644 --- a/docker/Dockerfile-go-builder +++ b/docker/Dockerfile-go-builder @@ -1,6 +1,6 @@ FROM golang:1.23.0-alpine3.20 ARG version -RUN apk add build-base +RUN apk add --no-cache build-base WORKDIR /app COPY go.* ./ RUN go mod download diff --git a/docker/Dockerfile-netclient-multiarch b/docker/Dockerfile-netclient-multiarch index e168d8cb..fbc7bfc1 100644 --- a/docker/Dockerfile-netclient-multiarch +++ b/docker/Dockerfile-netclient-multiarch @@ -13,7 +13,7 @@ FROM alpine:3.16.2 WORKDIR /root/ -RUN apk add --no-cache --update bash libmnl gcompat iptables openresolv iproute2 wireguard-tools +RUN apk add --no-cache bash libmnl gcompat iptables openresolv iproute2 wireguard-tools COPY --from=builder /app/netclient-app ./netclient COPY --from=builder /app/scripts/netclient.sh . RUN chmod 0755 netclient && chmod 0755 netclient.sh diff --git a/docker/Dockerfile-netclient-multiarch-userspace b/docker/Dockerfile-netclient-multiarch-userspace index 4a90c2e5..093af8b6 100644 --- a/docker/Dockerfile-netclient-multiarch-userspace +++ b/docker/Dockerfile-netclient-multiarch-userspace @@ -10,7 +10,7 @@ RUN GOOS=linux CGO_ENABLED=0 /usr/local/go/bin/go build -ldflags="-w -s" -o netc WORKDIR /root/ -RUN apk add --update git build-base libmnl-dev iptables +RUN apk add --no-cache git build-base libmnl-dev iptables RUN git clone https://git.zx2c4.com/wireguard-go && \ cd wireguard-go && \ @@ -28,7 +28,7 @@ FROM alpine:3.16.2 WORKDIR /root/ -RUN apk add --no-cache --update bash libmnl gcompat iptables openresolv iproute2 +RUN apk add --no-cache bash libmnl gcompat iptables openresolv iproute2 COPY --from=builder /usr/bin/wireguard-go /usr/bin/wg* /usr/bin/ COPY --from=builder /app/netclient-app ./netclient COPY --from=builder /app/scripts/netclient.sh .