mirror of
https://github.com/casjaysdevdocker/aria2
synced 2025-01-31 00:34:21 -05:00
🗃️ modified: Dockerfile 🗃️
This commit is contained in:
parent
cc22fffc3b
commit
6d690f4fa5
38
Dockerfile
38
Dockerfile
@ -1,12 +1,22 @@
|
|||||||
FROM casjaysdevdocker/nginx:latest as build
|
FROM casjaysdevdocker/alpine:latest as build
|
||||||
|
|
||||||
ARG ARIANG_VERSION=1.2.4 \
|
ARG LICENSE=WTFPL \
|
||||||
|
IMAGE_NAME=aria2 \
|
||||||
|
TIMEZONE=America/New_York \
|
||||||
|
PORT=6800 \
|
||||||
|
ARIANG_VERSION=1.2.4 \
|
||||||
DOMAIN=0.0.0.0:8080
|
DOMAIN=0.0.0.0:8080
|
||||||
|
|
||||||
|
ENV SHELL=/bin/bash \
|
||||||
|
TERM=xterm-256color \
|
||||||
|
HOSTNAME=${HOSTNAME:-casjaysdev-$IMAGE_NAME} \
|
||||||
|
TZ=$TIMEZONE
|
||||||
|
|
||||||
|
WORKDIR /usr/local/www/ariang
|
||||||
|
|
||||||
RUN mkdir -p /bin/ /config/ /data/ && \
|
RUN mkdir -p /bin/ /config/ /data/ && \
|
||||||
rm -Rf /bin/.gitkeep /config/.gitkeep /data/.gitkeep && \
|
rm -Rf /bin/.gitkeep /config/.gitkeep /data/.gitkeep && \
|
||||||
apk -U update && \
|
apk update -U --no-cache && \
|
||||||
apk add --no-cache \
|
apk add --no-cache \
|
||||||
aria2 \
|
aria2 \
|
||||||
unzip && \
|
unzip && \
|
||||||
@ -18,23 +28,21 @@ RUN mkdir -p /bin/ /config/ /data/ && \
|
|||||||
rsync -ahP /tmp/ariang/. /usr/local/www/ariang/ && \
|
rsync -ahP /tmp/ariang/. /usr/local/www/ariang/ && \
|
||||||
rm -Rf /tmp/ariang
|
rm -Rf /tmp/ariang
|
||||||
|
|
||||||
WORKDIR /usr/local/www/ariang
|
|
||||||
|
|
||||||
COPY ./config/. /etc/
|
|
||||||
COPY ./data/. /data/
|
|
||||||
COPY ./bin/. /usr/local/bin/
|
COPY ./bin/. /usr/local/bin/
|
||||||
|
COPY ./config/. /config/
|
||||||
|
COPY ./data/. /data/
|
||||||
|
|
||||||
FROM scratch
|
FROM scratch
|
||||||
ARG BUILD_DATE="$(date +'%Y-%m-%d %H:%M')"
|
ARG BUILD_DATE="$(date +'%Y-%m-%d %H:%M')"
|
||||||
|
|
||||||
LABEL org.label-schema.name="aria2" \
|
LABEL org.label-schema.name="aria2" \
|
||||||
org.label-schema.description="Aria2 downloader and AriaNg webui Docker image based on Alpine Linux" \
|
org.label-schema.description="Aria2 downloader and AriaNg webui Docker image based on Alpine Linux" \
|
||||||
org.label-schema.url="https://github.com/casjaysdevdocker/aria2/aria2" \
|
org.label-schema.url="https://hub.docker.com/r/casjaysdevdocker/aria2" \
|
||||||
org.label-schema.vcs-url="https://github.com/casjaysdevdocker/aria2/aria2" \
|
org.label-schema.vcs-url="https://github.com/casjaysdevdocker/aria2" \
|
||||||
org.label-schema.build-date=$BUILD_DATE \
|
org.label-schema.build-date=$BUILD_DATE \
|
||||||
org.label-schema.version=$BUILD_DATE \
|
org.label-schema.version=$BUILD_DATE \
|
||||||
org.label-schema.vcs-ref=$BUILD_DATE \
|
org.label-schema.vcs-ref=$BUILD_DATE \
|
||||||
org.label-schema.license="WTFPL" \
|
org.label-schema.license="$LICENSE" \
|
||||||
org.label-schema.vcs-type="Git" \
|
org.label-schema.vcs-type="Git" \
|
||||||
org.label-schema.schema-version="latest" \
|
org.label-schema.schema-version="latest" \
|
||||||
org.label-schema.vendor="CasjaysDev" \
|
org.label-schema.vendor="CasjaysDev" \
|
||||||
@ -46,11 +54,13 @@ ENV SHELL="/bin/bash" \
|
|||||||
TZ="${TZ:-America/New_York}"
|
TZ="${TZ:-America/New_York}"
|
||||||
|
|
||||||
WORKDIR /aria2
|
WORKDIR /aria2
|
||||||
VOLUME ["/aria2/data", "/aria2/config"]
|
|
||||||
EXPOSE 6800
|
VOLUME ["/root", "/aria2/data", "/aria2/config"]
|
||||||
|
|
||||||
|
EXPOSE $PORT
|
||||||
|
|
||||||
COPY --from=build /. /
|
COPY --from=build /. /
|
||||||
|
|
||||||
HEALTHCHECK CMD [ "/usr/local/bin/entrypoint-aria2.sh", "healthcheck" ]
|
HEALTHCHECK CMD ["/usr/local/bin/entrypoint-aria2.sh", "healthcheck"]
|
||||||
ENTRYPOINT [ "/usr/local/bin/entrypoint-aria2.sh" ]
|
|
||||||
|
|
||||||
|
ENTRYPOINT ["/usr/local/bin/entrypoint-aria2.sh"]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user