Move static-mirroring templates into their own dir
[mirror/dsa-puppet.git] / modules / roles / templates / static-mirroring / static-clients.conf.erb
diff --git a/modules/roles/templates/static-mirroring/static-clients.conf.erb b/modules/roles/templates/static-mirroring/static-clients.conf.erb
new file mode 100644 (file)
index 0000000..edbf313
--- /dev/null
@@ -0,0 +1,19 @@
+##
+## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
+##
+
+<%=
+
+mirrors = []
+scope.lookupvar('site::localinfo').keys.sort.each do |node|
+    if scope.lookupvar('site::localinfo')[node]['static_mirror']
+        mirrors << node
+    end
+end
+
+
+mirrors.join("\n")
+# vim:set et:
+# vim:set sts=4 ts=4:
+# vim:set shiftwidth=4:
+%>