diff --git a/Dockerfile b/Dockerfile index b8f8132bd3..a9753ef024 100644 --- a/Dockerfile +++ b/Dockerfile @@ -24,13 +24,33 @@ RUN CGO_ENABLED=0 \ -ldflags '-w -s -buildid=' \ -v -o /clash ./cmd/clash +FROM whatwewant/builder-node:v20-1 as builder-ui + +ADD https://github.com/doreamon-design/clash-board /build + +WORKDIR /build + +RUN yarn + +RUN yarn build + FROM whatwewant/alpine:v3.17-1 +ENV TZ=Asia/Shanghai + LABEL org.opencontainers.image.source="https://github.com/doreamon-design/clash" +ENV CLASH_OVERRIDE_EXTERNAL_UI_DIR=/etc/clash/ui + +ENV CLASH_CONFIG_FILE=/etc/clash/config.yaml + +ENV CLASH_HOME_DIR=/etc/clash + COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ -COPY --from=builder /Country.mmdb /root/.config/clash/ +COPY --from=builder-ui /build/dist /etc/clash/ui + +COPY --from=builder /Country.mmdb /etc/clash/ COPY --from=builder /clash /usr/bin diff --git a/constant/version.go b/constant/version.go index 17a26f8c7e..e243a78d72 100644 --- a/constant/version.go +++ b/constant/version.go @@ -1,6 +1,8 @@ package constant +import "github.com/doreamon-design/clash" + var ( - Version = "unknown version" + Version = clash.Version BuildTime = "unknown time" ) diff --git a/version.go b/version.go index 54e41164ee..02e3e224d1 100644 --- a/version.go +++ b/version.go @@ -1,4 +1,4 @@ package clash // Version is the version of lighthouse -var Version = "2.0.13" +var Version = "2.0.14"