Closed saltydk closed 2 years ago
No longer convinced that this is the right image.
Download paths are hard-coded out of the box in the crazy-max image and container does not shut down gracefully which means it won't close until docker sends SIGKILL, which seems sub-optimal to me.
@saltydk
Build on top
Dockerfile
ARG VERSION
FROM ghcr.io/crazy-max/rtorrent-rutorrent:${VERSION}
COPY ./root/04-overwrite.sh /etc/cont-init.d/04-overwrite.sh
RUN chmod a+x /etc/cont-init.d/04-overwrite.sh && mv /etc/cont-init.d/04-create-services.sh /etc/cont-init.d/05-create-services.sh
VOLUME [ "/data" ]
ENTRYPOINT [ "/init" ]
HEALTHCHECK --interval=30s --timeout=20s --start-period=10s \
CMD /usr/local/bin/healthcheck
#!/usr/bin/with-contenv sh
RU_DOWNLOAD_FOLDER=${RU_DOWNLOAD_FOLDER:-/downloads}
# Custom Folder
if [[ "${RU_DOWNLOAD_FOLDER}" != "/downloads" ]]; then
rm -rf /downloads/{complete,temp}
mkdir -p ${RU_DOWNLOAD_FOLDER} \
${RU_DOWNLOAD_FOLDER}/complete \
${RU_DOWNLOAD_FOLDER}/temp
echo " Enabling Custom Download Folder for rTorrent..."
sed -i "s#/downloads#${RU_DOWNLOAD_FOLDER}#g" /etc/rtorrent/.rtlocal.rc
echo "... Fixing perms for Custom Folders ..."
chown rtorrent. \
${RU_DOWNLOAD_FOLDER} \
${RU_DOWNLOAD_FOLDER}/complete \
${RU_DOWNLOAD_FOLDER}/temp
fii
The config issue is relatively easy to solve but the sigterm is likely more annoying to resolve outside of recreating the image entirely.
We didn't have this problem With SIGKILL
I can stop and and start without hard to kill the docker
Could be a differenc between ansible and composer again
Just run time docker stop rutorrent -t 60
and it'll take 60 seconds to exit.
Ya with -t but docker-compose stop rutorrent stop then with SIGKILL
I suspect your compose setup takes exactly 10 seconds to stop it. Which is the default timeout.
Maybe 15 max . It was just an idea .. since I read them
So I share my logic to overwrite them ..
I found it useful for you maybe 😉
Thanks for the attempt but the sigterm problem is big enough that I don't want to deal with it. Suspect qbittorrent will supersede rutorrent instead and might just move rutorrent to our community sandbox.
Maintaining container images that I do not personally run is not a good recipe for success imho.
Migrate rutorrent image to https://github.com/crazy-max/docker-rtorrent-rutorrent instead of the currently used one (horjulf/rutorrent-autodl).