From ddcd7c5ea5a1c13516637229ca6d6270559a87cf Mon Sep 17 00:00:00 2001 From: Julien Cristau Date: Sun, 29 Jan 2017 15:06:22 +0100 Subject: [PATCH] Make bacula-fd run as user bacula on stretch --- modules/bacula/files/bacula-fd-systemd | 2 ++ modules/bacula/manifests/client.pp | 7 +++++++ 2 files changed, 9 insertions(+) create mode 100644 modules/bacula/files/bacula-fd-systemd diff --git a/modules/bacula/files/bacula-fd-systemd b/modules/bacula/files/bacula-fd-systemd new file mode 100644 index 000000000..0dc6031fd --- /dev/null +++ b/modules/bacula/files/bacula-fd-systemd @@ -0,0 +1,2 @@ +[Service] +ExecStart=/usr/sbin/bacula-fd -f -u bacula -k -c $CONFIG diff --git a/modules/bacula/manifests/client.pp b/modules/bacula/manifests/client.pp index 7900e9a2f..0b2b67196 100644 --- a/modules/bacula/manifests/client.pp +++ b/modules/bacula/manifests/client.pp @@ -50,6 +50,13 @@ class bacula::client inherits bacula { require => Package['bacula-fd'], notify => Service['bacula-fd'], } + file { '/etc/systemd/system/bacula-fd.service.d/user.conf': + source => 'puppet:///modules/bacula/bacula-fd-systemd', + mode => '0400', + owner => root, + group => root, + notify => Service['bacula-fd'], + } @ferm::rule { 'dsa-bacula-fd-v4': domain => '(ip)', -- 2.20.1