diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2024-08-29 23:12:59 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2024-08-29 23:13:07 -0700 |
commit | 49156822ea3fd5062a00162238a36b3e6577ce7c (patch) | |
tree | bb7b71c1aa89099f6aff28e19085db2af0e067d0 | |
parent | rsync-gen.sh: Exclude all dotfiles, remove obsolete CVS exclude (diff) | |
download | mastermirror-scripts-49156822ea3fd5062a00162238a36b3e6577ce7c.tar.gz mastermirror-scripts-49156822ea3fd5062a00162238a36b3e6577ce7c.tar.bz2 mastermirror-scripts-49156822ea3fd5062a00162238a36b3e6577ce7c.zip |
feat(sync-origin-mirror-releases): save space on kestrel20240830T061350Z
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
-rwxr-xr-x | sync-origin-mirror-releases.sh | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/sync-origin-mirror-releases.sh b/sync-origin-mirror-releases.sh index c0e6d4a..128cb86 100755 --- a/sync-origin-mirror-releases.sh +++ b/sync-origin-mirror-releases.sh @@ -1,11 +1,24 @@ #!/bin/bash # Copyright 2011-2015 Gentoo Authors; Distributed under the GPL v2 +h=$(hostname --fqdn |cut -d. -f1) + FINALDIR="/data/mirror" PASSWD_FILE="" RSYNC="/usr/bin/rsync" RSYNC_ARGS="--recursive --links --perms --times --delete --hard-links --no-motd --timeout=300 ${PASSWD_FILE:+--password-file }${PASSWD_FILE}" -RSYNC_ARGS="${RSYNC_ARGS} --quiet" +RSYNC_ARGS+=" --quiet" + +case $h in + kestrel) + # kestrel is space constrained, and the binpackages can be re-generated. + # Saves 100+ GB + $RSYNC_ARGS+=" --exclude binpackages " + # kestrel is space constrained, and the snapshot squashfs are a nice-to-have: + # Saves 18 GB + $RSYNC_ARGS+=" --exclude squashfs " + ;; +esac module=releases ${RSYNC} ${RSYNC_ARGS} masterreleases.gentoo.org::${module}/ ${FINALDIR}/${module}/ |