diff --git a/REFERENCE.md b/REFERENCE.md index 225bced..e9a877a 100644 --- a/REFERENCE.md +++ b/REFERENCE.md @@ -10,8 +10,15 @@ ### Defined types +#### Public Defined types + * [`wireguard::interface`](#wireguardinterface): manages a wireguard setup +#### Private Defined types + +* `wireguard::provider::systemd`: Manage the systemd components of a wireguard setup +* `wireguard::provider::wgquick`: Manage the wg quick components of a wireguard setup + ### Data types * [`Wireguard::Peers`](#wireguardpeers): custom data type for an array with wireguard peers @@ -131,7 +138,6 @@ wireguard::interface {'as2273': wireguard::interface {'as3668-2': source_addresses => ['144.76.249.220', '2a01:4f8:171:1152::12'], public_key => 'Tci/bHoPCjTpYv8bw17xQ7P4OdqzGpEN+NDueNjUvBA=', - preshared_key => '/22q9I+RpWRsU+zshW8skv1p00TvnEE6fTvPJuI2Cp4=', endpoint => 'router02.bastelfreak.org:1338', dport => 1338, input_interface => $facts['networking']['primary'], @@ -141,7 +147,7 @@ wireguard::interface {'as3668-2': mtu => 1412, ``` -##### create a wireguard interface with multiple peers +##### create a wireguard interface with multiple peers where one uses a preshared key ```puppet wireguard::interface { 'wg0': @@ -150,6 +156,7 @@ wireguard::interface { 'wg0': peers => [ { public_key => 'foo==', + preshared_key => '/22q9I+RpWRsU+zshW8skv1p00TvnEE6fTvPJuI2Cp4=', allowed_ips => ['192.0.2.2'], }, { @@ -165,6 +172,7 @@ wireguard::interface { 'wg0': The following parameters are available in the `wireguard::interface` defined type: * [`interface`](#interface) +* [`ensure`](#ensure) * [`input_interface`](#input_interface) * [`manage_firewall`](#manage_firewall) * [`dport`](#dport) @@ -180,6 +188,7 @@ The following parameters are available in the `wireguard::interface` defined typ * [`routes`](#routes) * [`private_key`](#private_key) * [`preshared_key`](#preshared_key) +* [`provider`](#provider) ##### `interface` @@ -189,6 +198,14 @@ the title of the defined resource, will be used for the wg interface Default value: `$title` +##### `ensure` + +Data type: `Enum['present', 'absent']` + +will ensure that the files for the provider will be present or absent + +Default value: `'present'` + ##### `input_interface` Data type: `String[1]` @@ -305,10 +322,18 @@ Default value: ``undef`` Data type: `Optional[String[1]]` -Define preshared key which should be used for this interface +Define preshared key for the remote peer Default value: ``undef`` +##### `provider` + +Data type: `Enum['systemd', 'wgquick']` + +The specific backend to use for this `wireguard::interface` resource + +Default value: `'systemd'` + ## Data types ### `Wireguard::Peers` @@ -323,6 +348,7 @@ Alias of ```puppet Array[Struct[{ public_key => String[1], + preshared_key => Optional[String[1]], allowed_ips => Optional[Array[String[1]]], endpoint => Optional[String[1]], persistent_keepalive => Optional[Stdlib::Port], diff --git a/metadata.json b/metadata.json index 5521bb4..8ec0958 100644 --- a/metadata.json +++ b/metadata.json @@ -1,6 +1,6 @@ { "name": "puppet-wireguard", - "version": "1.1.1-rc0", + "version": "2.0.0-rc0", "author": "Vox Pupuli", "summary": "installs, configures, and manages wireguard", "license": "AGPL-3.0",