Update saz/ssh

This commit is contained in:
Andrew Tomaka 2014-04-01 17:14:44 -04:00
parent 6c78a8f79d
commit 954067c955
4 changed files with 24 additions and 20 deletions

View file

@ -1,11 +1,10 @@
forge "http://forge.puppetlabs.com" forge "http://forge.puppetlabs.com"
mod 'camptocamp/augeas', '0.0.1'
mod 'hunner/wordpress', '0.6.0' mod 'hunner/wordpress', '0.6.0'
mod 'jfryman/nginx', '0.0.9' mod 'jfryman/nginx', '0.0.9'
mod 'puppetlabs/apache', '0.10.0' mod 'puppetlabs/apache', '0.10.0'
mod 'puppetlabs/firewall', '1.0.2' mod 'puppetlabs/firewall', '1.0.2'
mod 'puppetlabs/mysql', '2.2.3' mod 'puppetlabs/mysql', '2.2.3'
mod 'saz/ssh', '1.2.0' mod 'saz/ssh', '2.3.3'
mod 'saz/sudo', '2.4.3' mod 'saz/sudo', '2.4.3'

View file

@ -1,7 +1,6 @@
FORGE FORGE
remote: http://forge.puppetlabs.com remote: http://forge.puppetlabs.com
specs: specs:
camptocamp/augeas (0.0.1)
hunner/wordpress (0.6.0) hunner/wordpress (0.6.0)
puppetlabs/concat (>= 1.0.0) puppetlabs/concat (>= 1.0.0)
puppetlabs/mysql (>= 2.1.0) puppetlabs/mysql (>= 2.1.0)
@ -21,17 +20,16 @@ FORGE
puppetlabs/mysql (2.2.3) puppetlabs/mysql (2.2.3)
puppetlabs/stdlib (>= 3.2.0) puppetlabs/stdlib (>= 3.2.0)
puppetlabs/stdlib (4.1.0) puppetlabs/stdlib (4.1.0)
saz/ssh (1.2.0) saz/ssh (2.3.3)
puppetlabs/stdlib (>= 2.2.1) puppetlabs/stdlib (>= 2.2.1)
saz/sudo (2.4.3) saz/sudo (2.4.3)
DEPENDENCIES DEPENDENCIES
camptocamp/augeas (= 0.0.1)
hunner/wordpress (= 0.6.0) hunner/wordpress (= 0.6.0)
jfryman/nginx (= 0.0.9) jfryman/nginx (= 0.0.9)
puppetlabs/apache (= 0.10.0) puppetlabs/apache (= 0.10.0)
puppetlabs/firewall (= 1.0.2) puppetlabs/firewall (= 1.0.2)
puppetlabs/mysql (= 2.2.3) puppetlabs/mysql (= 2.2.3)
saz/ssh (= 1.2.0) saz/ssh (= 2.3.3)
saz/sudo (= 2.4.3) saz/sudo (= 2.4.3)

View file

@ -8,15 +8,15 @@ user { 'jeff':
password => '$6$.AURF9sE09Q$..S10CFY7G.AVXzSW//w6GoV6yPzBzdvyUl8a7oyYbW/XzBU.o6AdHxTgTkCSWb64zmN3QoKovoUyLJhE/MFP/', password => '$6$.AURF9sE09Q$..S10CFY7G.AVXzSW//w6GoV6yPzBzdvyUl8a7oyYbW/XzBU.o6AdHxTgTkCSWb64zmN3QoKovoUyLJhE/MFP/',
} }
# Logging in with the root user must be disabled
include augeas
class { '::ssh::server': class { '::ssh::server':
require => Class['augeas'], storeconfigs_enabled => false,
} options => {
ssh::server::configline { 'PermitRootLogin': value => 'no' } # Logging in with the root user must be disabled
'PermitRootLogin' => 'no',
# SSH must be enabled on a non-standard port # SSH must be enabled on a non-standard port
ssh::server::configline { 'Port': value => '22984' } 'Port' => [22984],
},
}
# Install a working MySQL server # Install a working MySQL server
class { '::mysql::server': } class { '::mysql::server': }

View file

@ -65,8 +65,21 @@ package { 'mailutils': }
include augeas include augeas
include sudo include sudo
ssh::server::configline { 'Port': value => '22984' }
ssh::server::configline { 'PermitRootLogin': value => 'no' }
ssh::server::configline { 'PasswordAuthentication': value => 'yes' }
ssh::server::configline { 'AllowUsers/1': value => 'atomaka' }
ssh::server::configline { 'AllowUsers/2': value => 'jeff' }
class { '::ssh::server': class { '::ssh::server':
require => Class['augeas'], storeconfigs_enabled => false,
options => {
'Port' => [22984],
'PermitRootLogin' => 'no',
'PasswordAuthentication' => 'yes',
'AllowUsers/1' => 'atomaka',
'AllowUsers/2' => 'jeff',
},
} }
class { '::apache': class { '::apache':
@ -87,12 +100,6 @@ class { '::wordpress':
} }
# CONFIGURATIONS # CONFIGURATIONS
ssh::server::configline { 'Port': value => '22984' }
ssh::server::configline { 'PermitRootLogin': value => 'no' }
ssh::server::configline { 'PasswordAuthentication': value => 'yes' }
ssh::server::configline { 'AllowUsers/1': value => 'atomaka' }
ssh::server::configline { 'AllowUsers/2': value => 'jeff' }
sudo::conf { 'sudo': sudo::conf { 'sudo':
priority => 10, priority => 10,
content => "%sudo ALL=(ALL) NOPASSWD: ALL\n", content => "%sudo ALL=(ALL) NOPASSWD: ALL\n",