mirror of
https://github.com/bjdgyc/anylink.git
synced 2025-10-22 16:39:19 +08:00
修改 docker 编译
This commit is contained in:
@@ -42,7 +42,7 @@ COPY ./LICENSE /app/LICENSE
|
|||||||
COPY ./home /app/home
|
COPY ./home /app/home
|
||||||
|
|
||||||
#TODO 本地打包时使用镜像
|
#TODO 本地打包时使用镜像
|
||||||
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apk/repositories
|
#RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apk/repositories
|
||||||
RUN apk add --no-cache bash iptables iproute2\
|
RUN apk add --no-cache bash iptables iproute2\
|
||||||
&& chmod +x /app/docker_entrypoint.sh \
|
&& chmod +x /app/docker_entrypoint.sh \
|
||||||
&& ls /app
|
&& ls /app
|
||||||
|
@@ -14,11 +14,9 @@ uname -a
|
|||||||
|
|
||||||
cd /server
|
cd /server
|
||||||
|
|
||||||
go mod tidy
|
#go mod tidy
|
||||||
|
|
||||||
go build -o anylink -trimpath
|
go build -o anylink -trimpath -ldflags "-s -w -extldflags '-static' -X main.appVer=$appVer -X main.commitId=$commitId -X main.buildDate=$buildDate"
|
||||||
|
|
||||||
# -ldflags "-s -w -extldflags '-static' -X main.appVer=$appVer -X main.commitId=$commitId -X main.buildDate=$buildDate"
|
|
||||||
|
|
||||||
ls -l /server/
|
ls -l /server/
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user