From 60923cad87db0c765294e4a2aea69c394025ea18 Mon Sep 17 00:00:00 2001 From: Dnomd343 Date: Fri, 30 Sep 2022 16:22:14 +0800 Subject: [PATCH] build: fetch remote assets --- Dockerfile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 6a2b2b7..69a1334 100644 --- a/Dockerfile +++ b/Dockerfile @@ -49,11 +49,12 @@ WORKDIR /ClearDNS/build/ RUN cmake -DCMAKE_BUILD_TYPE=Release .. && make && mv ../bin/cleardns /tmp/ && strip /tmp/cleardns FROM ${ALPINE_IMG} AS asset -RUN apk add xz && mkdir -p /asset/ +RUN apk add xz +WORKDIR /asset/ RUN wget https://res.dnomd343.top/Share/cleardns/gfwlist.txt.xz && \ wget https://res.dnomd343.top/Share/cleardns/china-ip.txt.xz && \ wget https://res.dnomd343.top/Share/cleardns/chinalist.txt.xz && \ - xz -d *.xz && tar cJf /asset/assets.tar.xz ./*.txt + xz -d *.xz && tar cJf assets.tar.xz ./*.txt && rm *.txt COPY --from=dnsproxy /tmp/dnsproxy /asset/usr/bin/ COPY --from=overture /tmp/overture /asset/usr/bin/ COPY --from=adguard /tmp/AdGuardHome /asset/usr/bin/ @@ -62,4 +63,5 @@ COPY --from=toJSON /tmp/toJSON /asset/usr/bin/ FROM ${ALPINE_IMG} COPY --from=asset /asset/ / +WORKDIR /cleardns/ ENTRYPOINT ["cleardns"]