diff options
author | Luke Shumaker <lukeshu@parabola.nu> | 2018-09-25 22:26:11 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@parabola.nu> | 2018-09-26 12:41:13 -0400 |
commit | 4baff63b94d3921526884e5f16d70fdec815d711 (patch) | |
tree | 9ae8dfd41d3586b69121e1944a2355959a14f007 | |
parent | 02bba05a6a170a5534c933f7a25f3f1ea488545a (diff) |
Revert "Revert "Teach db-cleanup to clean old torrents, rather than having make_repo_torrents do it""
When I reverted this commit, I said:
> Since make_repo_torrents will now only place symlinks in TORRENTPOOL, the
> dead symlink removal will now handle it automatically, and db-cleanup needs
> no special knowledge of TORRENTPOOL.
However, that only means that we can *eventually* revert this. There
are still currently a ton of old plain files in TORRENTPOOL that need
cleaned up first.
Consider reverting this when the following comes back empty:
find "${FTP_DIR}/${TORRENTPOOL}" -type f
This reverts commit 840c13924da569fc38f45181b5ac2a059b6b143e.
-rwxr-xr-x | cron-jobs/db-cleanup | 2 | ||||
-rw-r--r-- | db-cleanup.conf | 9 |
2 files changed, 8 insertions, 3 deletions
diff --git a/cron-jobs/db-cleanup b/cron-jobs/db-cleanup index de92e21..fc7fd25 100755 --- a/cron-jobs/db-cleanup +++ b/cron-jobs/db-cleanup @@ -40,7 +40,7 @@ done | cut -d'/' -f1 | sort -u | sed "s|$|*|" > "$filter" msg "Removing old files:" -for POOL in "${PKGPOOLS[@]}" "${SRCPOOLS[@]}"; do +for POOL in "${PKGPOOLS[@]}" "${SRCPOOLS[@]}" "${TORRENTPOOLS[@]}"; do msg2 '%s' "${POOL}" rsync "${EXTRAFLAGS[@]}" -va --delete-excluded \ diff --git a/db-cleanup.conf b/db-cleanup.conf index 12d65f9..9944438 100644 --- a/db-cleanup.conf +++ b/db-cleanup.conf @@ -1,6 +1,6 @@ #!/hint/bash -# Both PKGPOOLS and SRCPOOLS are relative to `config:FTP_BASE`. +# All `*POOLS` variables are relative to `config:FTP_BASE`. # Directories where packages are shared between repos PKGPOOLS=( @@ -11,7 +11,7 @@ PKGPOOLS=( pool/community # Arch Linux (community) ) -# Directories where sources are stored +# Directories where source-packages are stored SRCPOOLS=( sources/parabola # Parabola GNU/Linux-libre sources/alarm # Arch Linux ARM @@ -19,3 +19,8 @@ SRCPOOLS=( sources/packages # Arch Linux (project) sources/community # Arch Linux (community) ) + +# Directories where torrents are stored +TORRENTPOOLS=( + torrents +) |