aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sign-binpackages.sh')
-rwxr-xr-xsign-binpackages.sh24
1 files changed, 20 insertions, 4 deletions
diff --git a/sign-binpackages.sh b/sign-binpackages.sh
index 4ae9dc0..2fe0ff9 100755
--- a/sign-binpackages.sh
+++ b/sign-binpackages.sh
@@ -2,14 +2,17 @@
# Copyright 2010-2023 Gentoo Authors; Distributed under the GPL v2
# might be earlier copyright, no history available
-# Keep this variable in sync in both sign-autobuilds.sh & sync-autobuilds.sh
+# for testing
+ARCHES="aarch64 sparc"
+
+# Keep this variable in sync
_ARCHES="alpha amd64 arm64 arm hppa ia64 loong m68k mips ppc riscv s390 sh sparc x86"
#alpha amd64 arm64 arm hppa ia64 loong m68k mips ppc riscv s390 sh sparc x86
ARCHES=${ARCHES:-${_ARCHES}}
-INTREE=blablabla
-SIGTREE=blablabla
+INTREE=/release/weekly/binpackages
+SIGTREE=/release/binpackages
DEBUG=''
VERBOSE=''
@@ -19,12 +22,25 @@ BINPKG_GPG_SIGNING_KEY=blablabla
gpgconf --kill all
+# step 0: ensure all directories exist and have the right
+# permissions
+
+for a in $ARCHES ; do
+ if ! [[ -d ${INTREE}/${a} ]]; then
+ mkdir -p ${INTREE}/${a}
+ chown ${a}:${a} ${INTREE}/${a}
+ chmod u+rwx,o+rx ${INTREE}/${a}
+ fi
+done
+
+[[ -d SIGTREE ]] || mkdir -p ${SIGTREE}
+
# step 1: rsync from the dirs where the arches copy in
# make sure to *not* overwrite existing newer files (obviously
# the signature changed them)...
for a in $ARCHES ; do
- rsync --recursive --delete --delete-after --update ${INTREE}/${a}/* ${SIGTREE}/${a}/
+ rsync --recursive --delete --delete-after --update ${INTREE}/${a}/ ${SIGTREE}/${a}/
done
# step 2: iterate over all binary package trees, sign