diff --git a/Dockerfile b/Dockerfile index 973484f9..b81f2209 100644 --- a/Dockerfile +++ b/Dockerfile @@ -48,3 +48,13 @@ COPY root/ / EXPOSE 8989 VOLUME /config + +HEALTHCHECK \ + --interval=30s \ + --timeout=10s \ + --start-period=60s \ + --retries=3 \ + CMD curl --fail --silent --show-error \ + --connect-timeout 2 \ + --max-time 5 \ + "http://127.0.0.1:8989$(awk -F'[<>]' '$2 == "UrlBase" { print $3; exit }' /config/config.xml)/ping" diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index 0e641109..26e42ccc 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -48,3 +48,13 @@ COPY root/ / EXPOSE 8989 VOLUME /config + +HEALTHCHECK \ + --interval=30s \ + --timeout=10s \ + --start-period=60s \ + --retries=3 \ + CMD curl --fail --silent --show-error \ + --connect-timeout 2 \ + --max-time 5 \ + "http://127.0.0.1:8989$(awk -F'[<>]' '$2 == "UrlBase" { print $3; exit }' /config/config.xml)/ping" diff --git a/readme-vars.yml b/readme-vars.yml index 54ddf677..107813c7 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -79,6 +79,7 @@ init_diagram: | "sonarr:latest" <- Base Images # changelog changelogs: + - {date: "29.07.26:", desc: "Add healthcheck."} - {date: "09.07.26:", desc: "Workaround malformed ncurses database."} - {date: "04.07.26:", desc: "Rebase to Alpine 3.24."} - {date: "15.01.26:", desc: "Rebase to Alpine 3.23."}