From 87cfaae69f29e156a7bcb5b1924b806056c4401c Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Fri, 15 Jun 2018 16:44:05 +0100 Subject: add EtcDefault.set Signed-off-by: Sean Whitton --- src/Propellor/Property/EtcDefault.hs | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/Propellor/Property/EtcDefault.hs (limited to 'src/Propellor/Property/EtcDefault.hs') diff --git a/src/Propellor/Property/EtcDefault.hs b/src/Propellor/Property/EtcDefault.hs new file mode 100644 index 00000000..0bda5c64 --- /dev/null +++ b/src/Propellor/Property/EtcDefault.hs @@ -0,0 +1,17 @@ +-- | Maintainer: Sean Whitton + +module Propellor.Property.EtcDefault ( + EtcDefaultFile, + set, +) where + +import Propellor.Base +import Propellor.Property.ConfFile + +-- | The name of a file in , without the prefix. +-- E.g. @useradd@. +type EtcDefaultFile = String + +-- | Set a key=value pair in a file in . +set :: EtcDefaultFile -> ShellKey -> String -> Property UnixLike +set f key value = containsShellSetting ("/etc/default" f) (key, value) -- cgit v1.2.3