From 08f7e4516c2dcc03813c767642327aa7c92ef189 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20Hamb=C3=BCchen?= Date: Wed, 2 Aug 2017 23:07:23 +0200 Subject: [PATCH] glusterfs service: Ensure log directory exists for glustereventsd. Prevents glustereventsd failing at startup in case it starts before glusterd has started (whose `preStart` would also create the needed directory). --- nixos/modules/services/network-filesystems/glusterfs.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/nixos/modules/services/network-filesystems/glusterfs.nix b/nixos/modules/services/network-filesystems/glusterfs.nix index f888ae36d98eb2..e7f2de0a2dc724 100644 --- a/nixos/modules/services/network-filesystems/glusterfs.nix +++ b/nixos/modules/services/network-filesystems/glusterfs.nix @@ -194,6 +194,10 @@ in after = [ "syslog.target" "network.target" ]; + preStart = '' + install -m 0755 -d /var/log/glusterfs + ''; + serviceConfig = { Type="simple"; Environment="PYTHONPATH=${glusterfs}/usr/lib/python2.7/site-packages";