tools: Add UPLOAD_DEST

Signed-off-by: Matt Turner <mattst88@gentoo.org>
This commit is contained in:
Matt Turner 2021-01-30 20:00:37 -05:00
parent 33ce8acb57
commit 8f478fe30b
14 changed files with 18 additions and 42 deletions

View file

@ -80,26 +80,14 @@ upload() {
--omit-dir-times
--delay-updates
)
rsync "${RSYNC_OPTS[@]}" "$@" ${UPLOAD_DEST}
rsync "${RSYNC_OPTS[@]}" "$@" ${UPLOAD_USER}@releng-incoming.gentoo.org:${UPLOAD_DEST}
}
post_build() {
local set=$1 spec=$2
case $HOSTNAME in
# If you ever need to ensure it's copied somewhere local, drop a hostname in here!
LOCAL)
DEST_DEFAULT=${BUILD_DESTDIR_BASE}
DEST_HARDENED=${BUILD_DESTDIR_BASE}/hardened
;;
*)
DEST_DEFAULT=${UPLOAD_USER}@releng-incoming.gentoo.org:${BUILD_DESTDIR_BASE}
DEST_HARDENED=${UPLOAD_USER}@releng-incoming.gentoo.org:${BUILD_DESTDIR_BASE}/hardened
;;
esac
pushd "${BUILD_SRCDIR_BASE}"/default >/dev/null || exit
UPLOAD_DEST=${DEST_DEFAULT}
UPLOAD_DEST=${BUILD_DESTDIR_BASE}
case ${spec} in
stage3.spec)
upload stage3-amd64-${TIMESTAMP}.tar.xz*
@ -126,7 +114,7 @@ post_build() {
popd >/dev/null || exit
pushd "${BUILD_SRCDIR_BASE}"/hardened >/dev/null || exit
UPLOAD_DEST=${DEST_HARDENED}
UPLOAD_DEST=${BUILD_DESTDIR_BASE}/hardened
case ${spec} in
hardened/stage3.spec)
upload stage3-amd64-hardened-${TIMESTAMP}.tar.xz*