diff options
author | Hendrik Jäger <gitcommit@henk.geekmail.org> | 2022-05-09 22:17:10 +0200 |
---|---|---|
committer | Hendrik Jäger <gitcommit@henk.geekmail.org> | 2022-07-25 23:53:04 +0200 |
commit | 34e6a9d0ab678ac69218a6be995b73c87e47b17c (patch) | |
tree | e0436476216d87f0ff606c7474a3b946be9a2ada /manifests/user_scandir.pp | |
parent | b63cb7937892c18a9c3c6da6b06e0c9a5fe7b3a1 (diff) |
implement user scandirs
Diffstat (limited to 'manifests/user_scandir.pp')
-rw-r--r-- | manifests/user_scandir.pp | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/manifests/user_scandir.pp b/manifests/user_scandir.pp new file mode 100644 index 0000000..db62fc3 --- /dev/null +++ b/manifests/user_scandir.pp @@ -0,0 +1,32 @@ +define s6::user_scandir( + Optional[String] $homedir = undef, +) { + $scandir = '/etc/s6-scandir' + + file { + "${scandir}/user_scandir_${title}": + ensure => directory, + ; + "${scandir}/user_scandir_${title}/run": + ensure => present, + content => epp('s6/user_scandir/run.epp', { 'username' => $title } ), + mode => '0744', + ; + "${scandir}/user_scandir_${title}/log": + ensure => directory, + ; + "${scandir}/user_scandir_${title}/log/run": + ensure => present, + content => epp('s6/user_scandir/log/run.epp', { 'username' => $title } ), + mode => '0744', + ; + [ + '/var/log/s6/', + "/var/log/s6/user_scandir_${title}/", + "/var/log/s6/user_scandir_${title}/logs/", + ]: + ensure => directory, + ; + } +} + |