From 413f6e60a5d3aa02e681b2d7638ebab30d193235 Mon Sep 17 00:00:00 2001 From: dnomd343 Date: Sun, 21 Aug 2022 14:59:11 +0800 Subject: [PATCH] build: fetch radvd from alpine repo --- Dockerfile | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9e0a0df..0d94f61 100644 --- a/Dockerfile +++ b/Dockerfile @@ -35,13 +35,6 @@ RUN env CGO_ENABLED=0 go build -v -o xproxy -trimpath \ COPY --from=upx /upx/ /usr/ RUN upx -9 /tmp/xproxy -FROM alpine:3.16 AS radvd -ENV RADVD_VERSION="2.19" -RUN apk add build-base byacc flex-dev linux-headers -RUN wget https://radvd.litech.org/dist/radvd-${RADVD_VERSION}.tar.xz && tar xf radvd-${RADVD_VERSION}.tar.xz -WORKDIR ./radvd-${RADVD_VERSION}/ -RUN ./configure && make && mv ./radvd ./radvdump /tmp/ && strip /tmp/radvd* - FROM alpine:3.16 AS asset WORKDIR /tmp/ RUN apk add xz @@ -49,11 +42,10 @@ RUN wget "https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/downlo RUN wget "https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geosite.dat" RUN mkdir -p /asset/ && tar cJf /asset/assets.tar.xz ./*.dat COPY --from=xproxy /tmp/xproxy /asset/usr/bin/ -COPY --from=radvd /tmp/radvd* /asset/usr/sbin/ COPY --from=proxy /tmp/*ray /asset/usr/bin/ FROM alpine:3.16 -RUN apk add --no-cache iptables ip6tables +RUN apk add --no-cache iptables ip6tables radvd COPY --from=asset /asset/ / WORKDIR /xproxy ENTRYPOINT ["xproxy"]