Added the current puppet stuff

This commit is contained in:
Monty Taylor 2011-07-14 13:13:12 -04:00
commit 6acac878c3
4 changed files with 102 additions and 0 deletions

24
files/sudoers Normal file
View File

@ -0,0 +1,24 @@
# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#
Defaults env_reset
# Host alias specification
# User alias specification
# Cmnd alias specification
#drizzle ALL = NOPASSWD: /usr/bin/pbuilder
# User privilege specification
root ALL=(ALL) ALL
# Uncomment to allow members of group sudo to not need a password
# (Note that later entries override this, so you might need to move
# it further down)
%wheel ALL=NOPASSWD: ALL

25
files/sudoers.Darwin Normal file
View File

@ -0,0 +1,25 @@
# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#
Defaults env_reset
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL) ALL
# Allow members of group sudo to execute any command after they have
# provided their password
# (Note that later entries override this, so you might need to move
# it further down)
%admin ALL=(ALL) NOPASSWD: ALL
#
#includedir /etc/sudoers.d

25
files/sudoers.Ubuntu Normal file
View File

@ -0,0 +1,25 @@
# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#
Defaults env_reset
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL) ALL
# Allow members of group sudo to execute any command after they have
# provided their password
# (Note that later entries override this, so you might need to move
# it further down)
%sudo ALL=(ALL) NOPASSWD: ALL
#
#includedir /etc/sudoers.d

28
manifests/init.pp Normal file
View File

@ -0,0 +1,28 @@
class sudoers {
group { 'wheel':
ensure => 'present'
}
group { 'sudo':
ensure => 'present'
}
group { 'admin':
ensure => 'present'
}
file { '/etc/sudoers':
owner => 'root',
group => 'root',
mode => 440,
ensure => 'present',
source => [
"puppet:///modules/sudoers/sudoers.$operatingsystem",
"puppet:///modules/sudoers/sudoers"
],
replace => 'true',
}
file { '/etc/alternatives/editor':
ensure => link,
target => "/usr/bin/vim.basic",
}
}