diff options
author | Jörg Thalheim <joerg@thalheim.io> | 2018-12-22 15:13:35 +0100 |
---|---|---|
committer | Jörg Thalheim <joerg@thalheim.io> | 2018-12-22 15:13:35 +0100 |
commit | 45986ec5873c978725ed482dc9a35e215ebb0438 (patch) | |
tree | 2f7fe2ead809affb59a483fce17c08334cfe0c27 /nixos | |
parent | dd3f755cf4e864bbf60613d5ca98d33ffbcbf9e6 (diff) |
nixos/vdr: create video directory automatically
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/modules/services/hardware/vdr.nix | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/nixos/modules/services/hardware/vdr.nix b/nixos/modules/services/hardware/vdr.nix index 39a656ec7e485..b0ecb944b5e31 100644 --- a/nixos/modules/services/hardware/vdr.nix +++ b/nixos/modules/services/hardware/vdr.nix @@ -25,7 +25,7 @@ in { videoDir = mkOption { type = types.path; default = "/srv/vdr/video"; - description = "Recording directory (must exist)"; + description = "Recording directory"; }; extraArguments = mkOption { @@ -39,6 +39,10 @@ in { ###### implementation config = mkIf cfg.enable { + systemd.tmpfiles.rules = [ + "d ${cfg.videoDir} 0755 vdr vdr 0" + "Z ${cfg.videoDir} - vdr vdr -" + ]; systemd.services.vdr = { description = "VDR"; |