]> git.ipfire.org Git - people/ms/nightly-builds.git/commitdiff
Revert "build.sh: Copy nightly builds onto NFS share"
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 6 Feb 2020 21:05:50 +0000 (21:05 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 6 Feb 2020 21:05:50 +0000 (21:05 +0000)
This reverts commit 8f86cdec28b2ba0401d711748ef34c8b251f7cc1.

NFS is slow as fuck.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
build.sh

index 227c7cfd73099f4a3be152f21d765ef31be1c9aa..a4e08afea31f24ef258a1a9e6ab7f6cfb4fee764 100755 (executable)
--- a/build.sh
+++ b/build.sh
@@ -4,7 +4,8 @@ BASEDIR="/build/nightly"
 LOCKFILE="/tmp/.nightly-builds.lock"
 
 UPLOAD_DIR="${BASEDIR}/upload"
-UPLOAD_TO="/pub/nightly"
+UPLOAD_TO="pakfire@fs01.haj.ipfire.org:/pub/nightly"
+RSYNC_ARGS=""
 
 extract_installer_from_iso() {
        local dir="${1}"
@@ -113,7 +114,12 @@ build() {
 sync() {
        mkdir -p "${UPLOAD_DIR}"
 
-       sudo -u pakfire rsync -avHz --no-owner --delay-updates --progress \
+       # Acquire a Kerberos ticket for authentication
+       if ! klist &>/dev/null; then
+               kinit -k -t /etc/krb5.keytab "host/${HOSTNAME}"
+       fi
+
+       rsync -avHz --progress ${RSYNC_ARGS} \
                "${UPLOAD_DIR}/" "${UPLOAD_TO}"
 }