services: zabbix-agent: Respect user and group configuration.

* gnu/services/monitoring.scm (zabbix-agent-account): Look up user and group
from CONFIG instead of hard-coded values.
This commit is contained in:
Marius Bakke 2022-01-25 15:49:09 +01:00
parent bbc2fb0d52
commit 88e4c8740a
No known key found for this signature in database
GPG key ID: A2A06DF2A33A54FA

View file

@ -431,8 +431,8 @@ (define-configuration zabbix-agent-configuration
(define (zabbix-agent-account config)
"Return the user accounts and user groups for CONFIG."
(let ((zabbix-user "zabbix")
(zabbix-group "zabbix"))
(let ((zabbix-user (zabbix-agent-configuration-user config))
(zabbix-group (zabbix-agent-configuration-group config)))
(list (user-group (name zabbix-group) (system? #t))
(user-account
(name zabbix-user)