amprolla

devuan's apt repo merger
git clone https://git.parazyd.org/amprolla
Log | Files | Refs | README | LICENSE

commit ecda256008e80e7182c0443331872db2186d9d95
parent 7071810df54ff41c2604850ab23fd6d61bbe1128
Author: KatolaZ <katolaz@freaknet.org>
Date:   Thu,  1 Nov 2018 12:18:25 +0000

introduced config variables in orchestrate.sh

Diffstat:
Morchestrate.sh | 17+++++++++++------
1 file changed, 11 insertions(+), 6 deletions(-)

diff --git a/orchestrate.sh b/orchestrate.sh @@ -6,8 +6,15 @@ # Make sure these correlate to lib/config.py AMPROLLA_UPDATE="${AMPROLLA_UPDATE:-/home/amprolla/amprolla/amprolla_update.py}" REPO_ROOT="${REPO_ROOT:-/home/amprolla/amprolla}" +AMPROLLA_LOCK="/run/lock/amprolla.lock" +RSYNC_URL="mirror@pkgmaster.devuan.org:/home/mirror/" + +[ -f "${AMPROLLA_LOCK}" ] || { + +[ -d "${REPO_ROOT}/merged-staging" ] || mkdir "${REPO_ROOT}/merged-staging" +[ -d "${REPO_ROOT}/merged-production" ] || mkdir "${REPO_ROOT}/merged-production" + -[ -f "/run/lock/amprolla.lock" ] || { ln -snf "$REPO_ROOT"/merged-staging "$REPO_ROOT"/merged # The break call is temporary to catch unhandled exceptions in the testing phase python3 "$AMPROLLA_UPDATE" || { @@ -26,8 +33,7 @@ echo "done!" printf "rsyncing production to pkgmaster... " rsync --delete -raX \ - "$REPO_ROOT"/merged-production/ \ - mirror@pkgmaster.devuan.org:/home/mirror/devuan/merged + "$REPO_ROOT"/merged-production/ "${RSYNC_URL}/merged" echo "done!" # handle obsolete package logs @@ -40,7 +46,6 @@ for i in $_logfiles; do done cp -f "$REPO_ROOT"/log/t/*.txt "$REPO_ROOT"/log/ -rsync "$REPO_ROOT"/log/t/*.txt mirror@pkgmaster.devuan.org:/home/mirror/devuan/ -rsync "$REPO_ROOT"/log/oldpackages.txt "$REPO_ROOT"/log/amprolla.txt \ - mirror@pkgmaster.devuan.org:/home/mirror/devuan/ +rsync "$REPO_ROOT"/log/t/*.txt ${RSYNC_URL} +rsync "$REPO_ROOT"/log/oldpackages.txt "$REPO_ROOT"/log/amprolla.txt ${RSYNC_URL} }