diff options
Diffstat (limited to 'manifests')
-rw-r--r-- | manifests/bootstrap/configurator.pp | 2 | ||||
-rw-r--r-- | manifests/bootstrap/host.pp | 7 | ||||
-rw-r--r-- | manifests/bootstrap/master.pp | 7 | ||||
-rw-r--r-- | manifests/bootstrap/vagrant.pp | 61 | ||||
-rw-r--r-- | manifests/classes/websites.pp | 42 | ||||
-rw-r--r-- | manifests/modules.pp | 6 | ||||
-rw-r--r-- | manifests/nodes.pp | 5 | ||||
-rw-r--r-- | manifests/nodes/default.pp | 3 | ||||
-rw-r--r-- | manifests/site.pp | 8 |
9 files changed, 35 insertions, 106 deletions
diff --git a/manifests/bootstrap/configurator.pp b/manifests/bootstrap/configurator.pp index d93a0ce..edcbe92 100644 --- a/manifests/bootstrap/configurator.pp +++ b/manifests/bootstrap/configurator.pp @@ -74,7 +74,7 @@ file { "$bootstrap_path/auth.conf": # # Basic users # -file { "$bootstrap_path/manifests/classes/users.pp": +file { "$bootstrap_path/modules/site_users/manifests/init.pp": ensure => present, mode => 0644, content => template("$templates/puppet/users.pp.erb"), diff --git a/manifests/bootstrap/host.pp b/manifests/bootstrap/host.pp index c1aead8..5f9c23a 100644 --- a/manifests/bootstrap/host.pp +++ b/manifests/bootstrap/host.pp @@ -4,11 +4,10 @@ # virtual machine. # -# Import site configuration -import "../site.pp" - # The server role -include nodo::role::server +class { 'nodo: + role => 'server', +} # Creates vserver for administrative node nodo::vserver::instance { "$hostname-master": diff --git a/manifests/bootstrap/master.pp b/manifests/bootstrap/master.pp index 51167f3..5934d3e 100644 --- a/manifests/bootstrap/master.pp +++ b/manifests/bootstrap/master.pp @@ -5,8 +5,7 @@ # Once it's running it can setup all the other nodes. # -# Import site configuration -import "../site.pp" - # Include the master node configuration -include nodo::role::master +class { 'nodo': + role => 'master', +} diff --git a/manifests/bootstrap/vagrant.pp b/manifests/bootstrap/vagrant.pp index 9206db6..47305dc 100644 --- a/manifests/bootstrap/vagrant.pp +++ b/manifests/bootstrap/vagrant.pp @@ -3,47 +3,36 @@ # virtual machine. # -# Import site configuration -import "../site.pp" - -# -# Stage definitions -# - -stage { 'first': - before => Stage['main'], -} - -stage { 'last': } -Stage['main'] -> Stage['last'] - # # Class definitions # # Vagrant classes -include nodo::role::vagrant - -class vagrant_config { - # Symlink to the mounted module folder - file { '/etc/puppet/modules': - ensure => '/etc/puppet/modules-0', - force => true, - } - - # Ensure a custom hiera configuration - file { '/etc/puppet/hiera.yaml': - owner => root, - group => root, - mode => 0644, - force => true, - ensure => '/etc/puppet/hiera/hiera.yaml', - } +class { 'nodo': + role => 'vagrant', } # -# Class instantiations -# -class { 'vagrant_config': - stage => first, -} +# LAMP example +# +#include database +# +#class { 'apache': +# default_folder => '/vagrant', +# default_user => 'vagrant', +# default_group => 'vagrant', +#} +# +# If you want to manage another website +#apache::site { "myapp": +# docroot => "/vagrant/", +# server_alias => 'myapp vagrant localhost', +# use => [ "Site myapp" ], +# tag => 'all', +# owner => vagrant, +# group => vagrant, +# mpm_user => vagrant, +# mpm_group => vagrant, +# password => '$5$NZfZqcdyZ3Xt$.kfZejriEJP3fc6RU0gBGEzMPQ/c3XiowVImB6VDrtD', +# shell => '/bin/bash', +#} diff --git a/manifests/classes/websites.pp b/manifests/classes/websites.pp deleted file mode 100644 index 35f27c6..0000000 --- a/manifests/classes/websites.pp +++ /dev/null @@ -1,42 +0,0 @@ -class websites::admin inherits websites::hosting::admin { - # An administrative Trac instance - #apache::site { "admin": - # docroot => "${apache::sites_folder}/admin/trac/htdocs", - # use => [ "Trac admin" ], - # redirect_match => "trac", - # mpm => false, - # tag => 'all', - #} - - apache::site { "munin": - docroot => '/var/www/munin', - owner => "munin", - group => "munin", - mpm => false, - tag => 'all', - } - - apache::site { "nagios": - source => true, - docroot => '/usr/share/nagios3/htdocs', - mpm => false, - tag => 'all', - } -} - -class websites inherits websites::hosting { - # Website definitions: always use tagged resources - - #apache::site { "site": - # source => true, - # ticket => '001', - # docroot => '/var/www/site', - # tag => 'all', - #} - - #database::instance { "site": - # password => 'xxx', - # tag => 'all', - #} - -} diff --git a/manifests/modules.pp b/manifests/modules.pp deleted file mode 100644 index 3df3fe3..0000000 --- a/manifests/modules.pp +++ /dev/null @@ -1,6 +0,0 @@ -# -# Module definitions. -# - -# Nodo automatically import all modules we need. -import "nodo" diff --git a/manifests/nodes.pp b/manifests/nodes.pp deleted file mode 100644 index b90f04e..0000000 --- a/manifests/nodes.pp +++ /dev/null @@ -1,5 +0,0 @@ -# -# Node definitions. -# - -#import "nodes/example.pp" diff --git a/manifests/nodes/default.pp b/manifests/nodes/default.pp new file mode 100644 index 0000000..5ebbf90 --- /dev/null +++ b/manifests/nodes/default.pp @@ -0,0 +1,3 @@ +node default { + include nodo +} diff --git a/manifests/site.pp b/manifests/site.pp deleted file mode 100644 index 6f3e5aa..0000000 --- a/manifests/site.pp +++ /dev/null @@ -1,8 +0,0 @@ -# -# Puppet site configuration. -# - -import "classes/users.pp" -import "classes/websites.pp" -import "modules.pp" -import "nodes.pp" |