|
@@ -1,12 +1,22 @@
|
|
|
-FROM ubuntu:22.04
|
|
|
|
|
|
|
+# syntax=docker/dockerfile:1
|
|
|
|
|
+FROM ubuntu:24.04
|
|
|
|
|
|
|
|
-EXPOSE 80
|
|
|
|
|
|
|
+ENV DEBIAN_FRONTEND=noninteractive \
|
|
|
|
|
+ PYTHONUNBUFFERED=1
|
|
|
|
|
+
|
|
|
|
|
+RUN apt-get update \
|
|
|
|
|
+ && apt-get install -y --no-install-recommends software-properties-common gpg-agent \
|
|
|
|
|
+ && add-apt-repository -y ppa:deluge-team/stable \
|
|
|
|
|
+ && apt-get install -y --no-install-recommends deluge-web \
|
|
|
|
|
+ && apt-get purge -y --auto-remove software-properties-common gpg-agent \
|
|
|
|
|
+ && rm -rf /var/lib/apt/lists/*
|
|
|
|
|
|
|
|
-RUN apt-get update && apt-get install -y software-properties-common
|
|
|
|
|
-RUN add-apt-repository ppa:deluge-team/stable -y
|
|
|
|
|
-RUN apt-get update && apt-get install -y deluge-web
|
|
|
|
|
|
|
+COPY --chmod=755 deluge-web_init.sh /usr/local/bin/deluge-web_init.sh
|
|
|
|
|
+
|
|
|
|
|
+VOLUME ["/config"]
|
|
|
|
|
+EXPOSE 80
|
|
|
|
|
|
|
|
-ADD deluge-web_init.sh /sbin/deluge-web_init.sh
|
|
|
|
|
-RUN chmod +x /sbin/deluge-web_init.sh
|
|
|
|
|
|
|
+HEALTHCHECK --interval=30s --timeout=5s --start-period=20s --retries=3 \
|
|
|
|
|
+ CMD python3 -c "import urllib.request; urllib.request.urlopen('http://127.0.0.1:80/', timeout=4)" || exit 1
|
|
|
|
|
|
|
|
-CMD /sbin/deluge-web_init.sh
|
|
|
|
|
|
|
+CMD ["/usr/local/bin/deluge-web_init.sh"]
|