From 43f94ff5a9bba9608b078e3ff9c74d66d3ab01f1 Mon Sep 17 00:00:00 2001 From: Florian Jacob Date: Sat, 14 Oct 2017 00:38:32 +0200 Subject: [PATCH] nixos/munin: move munin-cron to systemd.tmpfiles to match with munin-node. --- nixos/modules/services/monitoring/munin.nix | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/nixos/modules/services/monitoring/munin.nix b/nixos/modules/services/monitoring/munin.nix index 0ec201a0eb1..cc6d51f0ef1 100644 --- a/nixos/modules/services/monitoring/munin.nix +++ b/nixos/modules/services/monitoring/munin.nix @@ -215,9 +215,11 @@ in }; }; - system.activationScripts.munin-cron = stringAfter [ "users" "groups" ] '' - mkdir -p /var/{run,log,www,lib}/munin - chown -R munin:munin /var/{run,log,www,lib}/munin - ''; + systemd.tmpfiles.rules = [ + "d /var/run/munin 0755 munin munin -" + "d /var/log/munin 0755 munin munin -" + "d /var/www/munin 0755 munin munin -" + "d /var/lib/munin 0755 munin munin -" + ]; })]; }