addbuildtag

This commit is contained in:
root 2024-02-24 00:16:08 +08:00
parent fecd7463c9
commit 8c78edc441
2 changed files with 5 additions and 1 deletions

View File

@ -1,6 +1,8 @@
FROM alpine:3.14 as builder FROM alpine:3.14 as builder
ENV TZ=Asia/Shanghai ENV TZ=Asia/Shanghai
ARG TAG=main
ENV TAG=${TAG}
WORKDIR /app WORKDIR /app
ADD ./entrypoint.sh /app/entrypoint.sh ADD ./entrypoint.sh /app/entrypoint.sh
@ -19,6 +21,8 @@ RUN set -x\
&& source "$HOME/.cargo/env"\ && source "$HOME/.cargo/env"\
&& git clone https://github.com/zerotier/ZeroTierOne.git\ && git clone https://github.com/zerotier/ZeroTierOne.git\
&& cd ZeroTierOne\ && cd ZeroTierOne\
&& git checkout ${TAG}\
&& echo "切换到tag:${TAG}"\
&& make ZT_SYMLINK=1 \ && make ZT_SYMLINK=1 \
&& make\ && make\
&& make install\ && make install\

View File

@ -1,3 +1,3 @@
#!/bin/bash #!/bin/bash
docker build -t xubiaolin/zerotier-planet:latest . docker build --build-arg TAG=1.12.2 -t xubiaolin/zerotier-planet:latest .