[pmg-devel] [PATCH pmg-api v2 6/9] postinstall: make rrdcached be readable by the pmg group
Maximiliano Sandoval
m.sandoval at proxmox.com
Wed May 29 16:13:00 CEST 2024
Signed-off-by: Maximiliano Sandoval <m.sandoval at proxmox.com>
---
debian/postinst | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/debian/postinst b/debian/postinst
index 781b5dc..0d059af 100644
--- a/debian/postinst
+++ b/debian/postinst
@@ -60,6 +60,14 @@ migrate_pmg_smtp_filter() {
chown :pmg /var/lib/pmg
+ # FIXME: This is not ideal
+ if ! cat /etc/default/rrdcached | grep -q "^SOCKGROUP=pmg$"; then
+ sed -i "s/#SOCKGROUP=root/SOCKGROUP=pmg/" /etc/default/rrdcached
+ if systemctl --quiet is-active rrdcached.service ; then
+ deb-systemd-invoke reload-or-try-restart rrdcached.service >/dev/null || true
+ fi
+ fi
+
pmgdb update >/dev/null 2>&1 &
}
--
2.39.2
More information about the pmg-devel
mailing list