From bb26451cb335fdc9bc49763aa90a43d3d9de60ce Mon Sep 17 00:00:00 2001 From: Steffen Zieger Date: Fri, 24 Jan 2014 15:47:47 +0100 Subject: [PATCH] add gentoo support --- manifests/client/install.pp | 6 ++++-- manifests/params.pp | 8 ++++++++ manifests/server/install.pp | 6 ++++-- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/manifests/client/install.pp b/manifests/client/install.pp index e8259cb30..008a040b0 100644 --- a/manifests/client/install.pp +++ b/manifests/client/install.pp @@ -1,5 +1,7 @@ class ssh::client::install { - package { $ssh::params::client_package_name: - ensure => present, + if !defined(Package[$ssh::params::client_package_name]) { + package { $ssh::params::client_package_name: + ensure => present, + } } } diff --git a/manifests/params.pp b/manifests/params.pp index 52181c231..fb7fa2d5d 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -18,6 +18,14 @@ } default: { case $::operatingsystem { + gentoo: { + $server_package_name = 'openssh' + $client_package_name = 'openssh' + $sshd_config = '/etc/ssh/sshd_config' + $ssh_config = '/etc/ssh/ssh_config' + $ssh_known_hosts = '/etc/ssh/ssh_known_hosts' + $service_name = 'sshd' + } default: { fail("Unsupported platform: ${::osfamily}/${::operatingsystem}") } diff --git a/manifests/server/install.pp b/manifests/server/install.pp index bd0400edd..e2d6669e2 100644 --- a/manifests/server/install.pp +++ b/manifests/server/install.pp @@ -1,6 +1,8 @@ class ssh::server::install { include ssh::params - package { $ssh::params::server_package_name: - ensure => present, + if !defined(Package[$ssh::params::server_package_name]) { + package { $ssh::params::server_package_name: + ensure => present, + } } }