diff options
Diffstat (limited to 'manifests/subsystem/sshd.pp')
-rw-r--r-- | manifests/subsystem/sshd.pp | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/manifests/subsystem/sshd.pp b/manifests/subsystem/sshd.pp index 3327de8..c520c9e 100644 --- a/manifests/subsystem/sshd.pp +++ b/manifests/subsystem/sshd.pp @@ -1,14 +1,18 @@ class nodo::subsystem::sshd { - include ::sshd + $manage = hiera('nodo::subsystem::sshd::manage', true) - # Add the localhost ssh key, useful when one needs - # to ssh to localhost. - sshkey { [ 'localhost', '127.0.0.1' ]: - type => ssh-rsa, - key => $::sshrsakey, - ensure => $::sshrsakey ? { - '' => absent, - default => present, - }, + if $manage == true { + include ::sshd + + # Add the localhost ssh key, useful when one needs + # to ssh to localhost. + sshkey { [ 'localhost', '127.0.0.1' ]: + type => ssh-rsa, + key => $::sshrsakey, + ensure => $::sshrsakey ? { + '' => absent, + default => present, + }, + } } } |