summaryrefslogtreecommitdiff
path: root/manifests/init.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/init.pp')
-rw-r--r--manifests/init.pp20
1 files changed, 20 insertions, 0 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
new file mode 100644
index 0000000..83ccf1b
--- /dev/null
+++ b/manifests/init.pp
@@ -0,0 +1,20 @@
+# autossh tunnel interface
+#
+# TODO: User handling should be put somewhere. Here we are duplicating
+# code from backupninja module. Further developments should consider
+# have an unified user handling, maybe at puppet-user.
+#
+# For now, it's important to preserve the 'backupninja-' like tag
+# otherwise the behavior of this code will conflict with backupninja
+# and we'll see strange things like exported resources not being
+# realized.
+
+# this define realizes all needed resources for a hosted tunnel
+define tunnel_server_realize($host) {
+ User <<| tag == "backupninja-${host}" |>>
+ File <<| tag == "backupninja-${host}" |>>
+ Ssh_authorized_key <<| tag == "backupninja-${host}" |>>
+}
+
+class tunnel {
+}