From fe92ce01fabe2d1b6a966d119e24c07cd164b776 Mon Sep 17 00:00:00 2001 From: varac Date: Mon, 9 Nov 2015 10:22:58 +0100 Subject: [feat] Optinally disable exported resources If run masterless, we cannot export resources, so we move them to an own class. Including it can be disabled by passing "use_storedconfig" to the sshd class. --- manifests/sshkey.pp | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 manifests/sshkey.pp (limited to 'manifests/sshkey.pp') diff --git a/manifests/sshkey.pp b/manifests/sshkey.pp new file mode 100644 index 0000000..df37a66 --- /dev/null +++ b/manifests/sshkey.pp @@ -0,0 +1,21 @@ +# deploys the +class sshd::sshkey { + + @@sshkey{$::fqdn: + ensure => present, + tag => 'fqdn', + type => 'ssh-rsa', + key => $::sshrsakey, + } + + # In case the node has uses a shared network address, + # we don't define a sshkey resource using an IP address + if $sshd::shared_ip == 'no' { + @@sshkey{$::sshd::sshkey_ipaddress: + ensure => present, + tag => 'ipaddress', + type => 'ssh-rsa', + key => $::sshrsakey, + } + } +} -- cgit v1.2.3