Skip to content

Commit

Permalink
放弃环境变量
Browse files Browse the repository at this point in the history
  • Loading branch information
ryjer committed Sep 13, 2023
1 parent cb5eaeb commit ac805b6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ jobs:
tags: |
ryjer/opentracker:latest
ryjer/opentracker:20210823
ryjer/opentracker:20210823-alpine
# 处理缓存无限增大问题的临时修复,以防出现问题。(等待github官方修复)
#- name: Move cache
Expand Down
12 changes: 6 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,17 @@ COPY --from=build /src/opentracker/opentracker /bin/opentracker

# 创建配置目录,安装 curl 健康检查使用
RUN apk add --no-cache curl \
&& mkdir -p ${XDG_CONFIG_HOME}
&& mkdir -p /config

# 对外暴露配置卷路径
VOLUME ["${XDG_CONFIG_HOME}"]
VOLUME ["/config"]

# 复制配置文件到配置路径
COPY ./opentracker.conf ${XDG_CONFIG_HOME}/opentracker.conf
COPY ./whitelist ${XDG_CONFIG_HOME}/whitelist
COPY ./blacklist ${XDG_CONFIG_HOME}/blacklist
COPY ./opentracker.conf /config/opentracker.conf
COPY ./whitelist /config/whitelist
COPY ./blacklist /config/blacklist

EXPOSE 6969/tcp
EXPOSE 6969/udp

CMD ["/bin/opentracker", "-f", "${XDG_CONFIG_HOME}/opentracker.conf"]
CMD ["/bin/opentracker", "-f", "/config/opentracker.conf"]

0 comments on commit ac805b6

Please sign in to comment.