From 0faaad53fe4d6816421c8e599466256eb56b620b Mon Sep 17 00:00:00 2001 From: classabbyamp Date: Sun, 13 Aug 2023 15:31:17 -0400 Subject: [PATCH] services/nomad/build/buildsync-{aarch64,musl}.nomad: use lsyncd instead of a cron job, use rwc to trigger rsync jobs. This should also push to the glibc builder now, instead of the glibc builder pulling from the other builders --- services/nomad/build/buildsync-aarch64.nomad | 51 +++++++++++--------- services/nomad/build/buildsync-musl.nomad | 51 +++++++++++--------- 2 files changed, 58 insertions(+), 44 deletions(-) diff --git a/services/nomad/build/buildsync-aarch64.nomad b/services/nomad/build/buildsync-aarch64.nomad index d5a3a6f3..54d9c4cb 100644 --- a/services/nomad/build/buildsync-aarch64.nomad +++ b/services/nomad/build/buildsync-aarch64.nomad @@ -4,6 +4,7 @@ job "buildsync-aarch64" { namespace = "build" group "rsync" { + count = 1 network { mode = "bridge" } volume "root-pkgs" { @@ -13,20 +14,11 @@ job "buildsync-aarch64" { } task "rsync" { - leader = true driver = "docker" - vault { - policies = ["void-secrets-buildsync"] - } - config { - image = "eeacms/rsync" - args = ["client"] - } - - env { - CRON_TASK_1="*/5 * * * * flock -n /run/rsync.lock rsync -vurk -e 'ssh -i /secrets/id_rsa -o UserKnownHostsFile=/local/known_hosts' --exclude '*.sig' --delete-after -f '+ */' -f '+ aarch64*-repodata' -f '+ *.aarch64*.xbps' -f '+ *.noarch*.xbps' -f '+ otime' -f '- *' void-buildsync@b-fsn-de.node.consul:/hostdir/binpkgs/ /pkgs/aarch64" + image = "ghcr.io/void-linux/infra-lsyncd:202308" # TODO + volumes = ["local/lsyncd.conf:/etc/lsyncd.conf"] } volume_mount { @@ -36,19 +28,34 @@ job "buildsync-aarch64" { template { data = <