newer pg module
[mirror/dsa-puppet.git] / 3rdparty / modules / postgresql / lib / puppet / type / postgresql_replication_slot.rb
diff --git a/3rdparty/modules/postgresql/lib/puppet/type/postgresql_replication_slot.rb b/3rdparty/modules/postgresql/lib/puppet/type/postgresql_replication_slot.rb
new file mode 100644 (file)
index 0000000..b5b317c
--- /dev/null
@@ -0,0 +1,16 @@
+Puppet::Type.newtype(:postgresql_replication_slot) do
+  @doc = "Manages Postgresql replication slots.
+
+This type allows to create and destroy replication slots
+to register warm standby replication on a Postgresql
+master server.
+"
+
+  ensurable
+
+  newparam(:name) do
+    desc "The name of the slot to create. Must be a valid replication slot name."
+    isnamevar
+    newvalues /^[a-z0-9_]+$/
+  end
+end