class sshd::client::base {
- case $sshd_ensure_version {
- '': { $sshd_ensure_version = "present" }
- }
-
- package{openssh-clients:
- ensure => $sshd_ensure_version,
- }
-
# this is needed because the gid might have changed
file { '/etc/ssh/ssh_known_hosts':
mode => 0644, owner => root, group => 0;
}
class sshd::client::linux inherits sshd::client::base {
+ if $ssh_ensure_version == '' { $ssh_ensure_version = 'installed' }
+ package {'openssh-clients':
+ ensure => $ssh_ensure_version,
+ }
}
-class sshd::client::debian inherits sshd::client::linux {
+class sshd::client::debian inherits sshd::client::linux {
Package['openssh-clients']{
name => 'openssh-client',
}
# $sshd_use_pam = yes
# include sshd::debian
#
+# If you need to install a version of the ssh daemon or client package other than
+# the default one that would be installed by 'ensure => installed', then you can
+# set the following variables:
+#
+# $sshd_ensure_version = "1:5.2p2-6"
+# $ssh_ensure_version = "1:5.2p2-6"
+#
# The following is a list of the currently available variables:
#
# sshd_listen_address: specify the addresses sshd should listen on
'': { $sshd_ensure_version = "present" }
}
- package{openssh:
- ensure => $sshd_ensure_version,
- }
-
file { 'sshd_config':
path => '/etc/ssh/sshd_config',
owner => root,
}
class sshd::linux inherits sshd::base {
+ if $sshd_ensure_version == '' { $sshd_ensure_version = 'installed' }
+ package {'openssh':
+ ensure => $sshd_ensure_version,
+ }
File[sshd_config]{
require +> Package[openssh],
}