From 48145c35731973db08b4f68f2ec876cf7938d0b0 Mon Sep 17 00:00:00 2001 From: "Dustin C. Hatch" Date: Fri, 19 Jan 2024 20:10:11 -0600 Subject: [PATCH] nut: Enable Podman auto-update for containers Setting `AutoUpdate=registry` will tell Podman to automatically fetch an updated container image from its corresponding registry and restart the container. The `podman-auto-update.timer` systemd unit needs to be active for this to happen on a schedule. --- templates/nut/nut-monitor.container | 1 + templates/nut/nut-server.container | 1 + 2 files changed, 2 insertions(+) diff --git a/templates/nut/nut-monitor.container b/templates/nut/nut-monitor.container index 8032b4d..58202c9 100644 --- a/templates/nut/nut-monitor.container +++ b/templates/nut/nut-monitor.container @@ -8,6 +8,7 @@ After=nut-server.service [Container] Image=git.pyrocufflink.net/containerimages/nut:latest Pull=newer +AutoUpdate=registry Exec=upsmon -F User=nut RunInit=true diff --git a/templates/nut/nut-server.container b/templates/nut/nut-server.container index c8f9788..3fec87f 100644 --- a/templates/nut/nut-server.container +++ b/templates/nut/nut-server.container @@ -10,6 +10,7 @@ After=reload-udev-rules.path [Container] Image=git.pyrocufflink.net/containerimages/nut:latest Pull=newer +AutoUpdate=registry RunInit=true Volume=%t/containers/udev-rules:/etc/udev/rules.d:rw,z Volume=/etc/ups:/etc/ups:ro