Open 188334911 opened 1 year ago
其实,对于autoremove-torrents来说,最好的使用方式是在宿主机上安装,而非在容器中。如果非要在容器中安装的话,不需要我做什么,你自己就可以完成:
INSTALL_PYTHON
设置为true
,EXTRA_PACKAGES
添加一个包py3-pip
;#!/usr/bin/with-contenv bash
if ! type autoremove-torrents &>/dev/null; then
pip install -i https://mirrors.bfsu.edu.cn/pypi/web/simple cython autoremove-torrents
fi
/etc/cont-init.d/60-autoremove-torrents
即可。如果方式一存在依赖问题,就换直接安装的方式。
INSTALL_PYTHON
设置为true
,EXTRA_PACKAGES
添加一个包git
;#!/usr/bin/with-contenv bash
if ! type autoremove-torrents &>/dev/null; then
git clone https://github.com/jerrymakesjelly/autoremove-torrents.git /data/diy/autoremove-torrents
cd /data/diy/autoremove-torrents
python3 setup.py install
fi
/etc/cont-init.d/60-autoremove-torrents
即可。感谢大佬码字,学习了~
目前的版本功能已经非常强悍了,感谢作者,特别是列出清理未做种的文件,解决了我十年pt堆积的垃圾文件的问题, 因为有些文件不会一直保留,看过就删,每次都需要手动删除种子,有个特别好的项目autoremove-torrents,使用python写的,可以自动删除符合条件的种子,集成到镜像里面应该没有太大的问题,我自己安装过,但是问题就是每次更新镜像以后又要重新装,如果可以集成就更好了.
项目地址: https://github.com/jerrymakesjelly/autoremove-torrents/blob/master/README-cn.rst