compute image: dbus for slurmd's systemd scope; controller slurm.conf sync timer
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
7fe7c26e22
commit
c81b498df1
4 files changed
+27
No files matched your search
@@ -31,8 +31,13 @@ chgrp -R rollcall /etc/rollcall/overlays
|
||||
install -d -m 0755 /var/lib/rollcall
|
||||
install -d -m 0755 -o rollcall -g rollcall /var/lib/rollcall/dnsmasq
|
||||
install -m 0644 rollcall-dnsmasq.path rollcall-dnsmasq.service /etc/systemd/system/
|
||||
# optional: this host is also the Slurm controller -> keep its slurm.conf rendered from the profile
|
||||
install -m 0644 rollcall-controller-sync.service rollcall-controller-sync.timer /etc/systemd/system/
|
||||
systemctl daemon-reload
|
||||
systemctl enable --now rollcall-dnsmasq.path >/dev/null 2>&1 || true
|
||||
if systemctl list-unit-files slurmctld.service >/dev/null 2>&1 && [ -d /etc/slurm ]; then
|
||||
systemctl enable --now rollcall-controller-sync.timer >/dev/null 2>&1 || true
|
||||
fi
|
||||
systemctl enable --now rollcall.service
|
||||
systemctl restart rollcall.service
|
||||
sleep 1
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=rollcall: keep the local Slurm controller's slurm.conf in sync with the rendered profile
|
||||
After=rollcall.service
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
# PROFILE is the profile whose overlay carries slurm.conf
|
||||
Environment=PROFILE=compute
|
||||
ExecStart=/bin/sh -c 'set -e; new=$(/usr/local/bin/rollcall render "$PROFILE" etc/slurm/slurm.conf) || exit 0; \
|
||||
if ! printf "%%s\n" "$new" | grep -v "^# rendered by rollcall" | cmp -s - <(grep -v "^# rendered by rollcall" /etc/slurm/slurm.conf 2>/dev/null); then \
|
||||
printf "%%s\n" "$new" > /etc/slurm/slurm.conf.new && mv /etc/slurm/slurm.conf.new /etc/slurm/slurm.conf; \
|
||||
systemctl try-restart slurmctld.service; echo "slurm.conf updated"; fi'
|
||||
@@ -0,0 +1,9 @@
|
||||
[Unit]
|
||||
Description=rollcall: controller slurm.conf sync every minute
|
||||
|
||||
[Timer]
|
||||
OnBootSec=1min
|
||||
OnUnitActiveSec=1min
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
||||
@@ -33,3 +33,4 @@ firmware-qlogic
|
||||
firmware-realtek
|
||||
amd64-microcode
|
||||
intel-microcode
|
||||
dbus
|
||||
Reference in new issue
Block a user