View default.pp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'mysql' | |
import 'apache' | |
node default { | |
include users | |
include db | |
include apache_server | |
exec {"apt-update": | |
command => "apt-get update", |
View createdb.pp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define mysql::createdb { | |
exec { "create-${name}-db": | |
unless => "mysql -uroot -p${config::mysqlRootPassword} ${name}", | |
command => "mysql -uroot -p${config::mysqlRootPassword} -e \"create database ${name}; grant all on ${name}.* to ${config::dbUser}@localhost identified by '${config::dbPassword}';\"", | |
require => Service["mysql"], | |
} | |
} |
View gist:2514198
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class config { | |
include config::install, config::config, config::service | |
Class['puppet::service'] -> Class['config::install'] | |
} |
View gist:2514196
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class config { | |
include config::install, config::config, config::service | |
Class['config::install'] -> Class['puppet::service'] | |
} |
View gist:2514092
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class hostgroup::frontend { | |
include passenger | |
include nodejs | |
include nrpe::rubyprocs | |
} | |
class passenger { | |
include apache |
View gist:2511951
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apache::params: | |
class apache::params { | |
$vgname = 'vg01' | |
$lvname = 'wwwlv' | |
$lvsize = '2G' | |
$fstype = 'ext4' | |
$fsname = "/dev/${vgname}/${lvname}" |
View gist:2484287
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
file { '/etc/yum.repos.d/': | |
ensure => directory, | |
mode => '0755', | |
force => true, | |
purge => true, | |
recurse => true, | |
} | |
View gist:2345614
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$perl_modules = [ 'Data::Pageset', 'perl-module-b' ] | |
perlbrew::install_modules { | |
$perl_modules: | |
perl => 'a-version-of-perl' | |
} | |
perlbrew::install_modules { | |
$perl_modules: |
View gist:1895471
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class sshd::data { | |
$enable = extlookup('sshd_enable', 'present') | |
} | |
class sshd { | |
include sshd::params, sshd::data |