summaryrefslogtreecommitdiff
path: root/manifests/mounts/instance.pp
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-04-19 16:10:16 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2022-04-19 16:29:06 +0200
commitd63ee5160ba3895ebbff932db0465e3b731fceeb (patch)
treea5e34d118dcd9c7ab058c9be6b054251092b9809 /manifests/mounts/instance.pp
parentFix profiles::common::debian using $name. (diff)
downloadprofiles-d63ee5160ba3895ebbff932db0465e3b731fceeb.tar.gz
profiles-d63ee5160ba3895ebbff932db0465e3b731fceeb.tar.xz
profiles::mounts now takes data from hiera.
Diffstat (limited to '')
-rw-r--r--manifests/mounts/instance.pp19
1 files changed, 19 insertions, 0 deletions
diff --git a/manifests/mounts/instance.pp b/manifests/mounts/instance.pp
new file mode 100644
index 0000000..3b87b81
--- /dev/null
+++ b/manifests/mounts/instance.pp
@@ -0,0 +1,19 @@
+define profiles::mounts::instance (
+ String $what,
+ String $where = $name,
+ Array[String] $options = [],
+) {
+
+ file { $where:
+ ensure => directory,
+ }
+
+ systemd_mount { $where:
+ what => $what,
+ where => $where,
+ wantedBy => 'remote-fs.target',
+ automount => true,
+ require => File[$where],
+ options => $options,
+ }
+}