mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-06-26 13:14:14 +00:00
logs
This commit is contained in:
parent
af7232d545
commit
4e7421d0f3
1 changed files with 10 additions and 2 deletions
12
.github/docker/Dockerfile
vendored
12
.github/docker/Dockerfile
vendored
|
@ -10,17 +10,25 @@ ADD https://github.com/v2fly/domain-list-community/releases/latest/download/dlc.
|
||||||
ADD https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geoip.dat /loyalsoldier/geoip.dat
|
ADD https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geoip.dat /loyalsoldier/geoip.dat
|
||||||
ADD https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geosite.dat /loyalsoldier/geosite.dat
|
ADD https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geosite.dat /loyalsoldier/geosite.dat
|
||||||
|
|
||||||
# chainguard/static contains only tzdata and ca-certificates, can be built with multiarch static binaries.
|
FROM --platform=linux/amd64 alpine:latest
|
||||||
FROM --platform=linux/amd64 chainguard/static:latest
|
|
||||||
WORKDIR /var/log/xray
|
WORKDIR /var/log/xray
|
||||||
COPY .github/docker/files/config.json /etc/xray/config.json
|
COPY .github/docker/files/config.json /etc/xray/config.json
|
||||||
COPY --from=build --chmod=755 /src/xray /usr/bin/xray
|
COPY --from=build --chmod=755 /src/xray /usr/bin/xray
|
||||||
|
|
||||||
|
RUN mkdir -p /var/log/xray && \
|
||||||
|
touch /var/log/xray/access.log && \
|
||||||
|
touch /var/log/xray/error.log && \
|
||||||
|
ln -sf /dev/stdout /var/log/xray/access.log && \
|
||||||
|
ln -sf /dev/stderr /var/log/xray/error.log
|
||||||
|
|
||||||
USER root
|
USER root
|
||||||
WORKDIR /root
|
WORKDIR /root
|
||||||
VOLUME /etc/xray
|
VOLUME /etc/xray
|
||||||
ARG TZ=Asia/Shanghai
|
ARG TZ=Asia/Shanghai
|
||||||
ENV TZ=$TZ
|
ENV TZ=$TZ
|
||||||
|
|
||||||
|
RUN apk add --no-cache tzdata
|
||||||
|
|
||||||
ENTRYPOINT [ "/usr/bin/xray" ]
|
ENTRYPOINT [ "/usr/bin/xray" ]
|
||||||
CMD [ "-config", "/etc/xray/config.json" ]
|
CMD [ "-config", "/etc/xray/config.json" ]
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue