diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2016-03-05 22:16:31 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2016-03-05 22:16:31 -0300 |
commit | 364912a73905340ea2d48598afbd990914b2e0d9 (patch) | |
tree | ff56c78dafdac7b8ed1303f7b574b4d560382292 /manifests/examples | |
parent | 85d41ce300772173c312b3dcc9afb4de862a3955 (diff) | |
download | puppet-bootstrap-364912a73905340ea2d48598afbd990914b2e0d9.tar.gz puppet-bootstrap-364912a73905340ea2d48598afbd990914b2e0d9.tar.bz2 |
Adds examples
Diffstat (limited to 'manifests/examples')
-rw-r--r-- | manifests/examples/laravel.pp | 48 | ||||
-rw-r--r-- | manifests/examples/silex.pp | 44 | ||||
-rw-r--r-- | manifests/examples/symfony.pp | 28 |
3 files changed, 120 insertions, 0 deletions
diff --git a/manifests/examples/laravel.pp b/manifests/examples/laravel.pp new file mode 100644 index 0000000..3554ffd --- /dev/null +++ b/manifests/examples/laravel.pp @@ -0,0 +1,48 @@ +class laravel { + include php + include database + include nodo::utils::web + include websites + + # Laravel requirement + package { 'php5-mcrypt': + ensure => installed, + } + + apache::site { "laravel": + docroot => "/vagrant/laravel/public", + server_alias => 'vagrant localhost', + use => [ "Site laravel" ], + tag => 'all', + owner => vagrant, + group => vagrant, + mpm_user => vagrant, + mpm_group => vagrant, + password => '$5$iu01VZigQlBm5OUb$2W9AmvI/tjwxSTYYMOHOmwYpann.PTl8jdcycp.fpl4', + shell => '/bin/bash', + } + + database::instance { "laravel": + password => 'laravel', + tag => 'all', + } + + # TODO + #curl -sS https://getcomposer.org/installer | php + #sudo mv composer.phar /usr/local/bin/composer + #cd /vagrant && rm -rf laravel + #composer create-project laravel/laravel laravel --prefer-dist + + exec { 'create-laravel': + command => '/usr/local/bin/composer create-project laravel/laravel laravel --prefer-dist', + user => 'vagrant', + cwd => '/vagrant', + } +} + +# +# Class instantiations +# +class { 'laravel': + stage => main, +} diff --git a/manifests/examples/silex.pp b/manifests/examples/silex.pp new file mode 100644 index 0000000..19fdd1f --- /dev/null +++ b/manifests/examples/silex.pp @@ -0,0 +1,44 @@ +# Main class +class silex { + include php + include database + include nodo::utils::web + include websites + + apache::site { "silex": + docroot => "/vagrant/silex/web", + server_alias => 'vagrant localhost', + use => [ "Site silex" ], + tag => 'all', + owner => vagrant, + group => vagrant, + mpm_user => vagrant, + mpm_group => vagrant, + password => '$5$iu01VZigQlBm5OUb$2W9AmvI/tjwxSTYYMOHOmwYpann.PTl8jdcycp.fpl4', + shell => '/bin/bash', + } + + database::instance { "silex": + password => 'silex', + tag => 'all', + } + + # TODO + #curl -sS https://getcomposer.org/installer | php + #sudo mv composer.phar /usr/local/bin/composer + #cd /vagrant/silex + #composer install + + exec { 'composer-install': + command => '/usr/local/bin/composer install', + user => 'vagrant', + cwd => '/vagrant/silex', + } +} + +# +# Class instantiations +# +class { 'silex': + stage => main, +} diff --git a/manifests/examples/symfony.pp b/manifests/examples/symfony.pp new file mode 100644 index 0000000..2829b98 --- /dev/null +++ b/manifests/examples/symfony.pp @@ -0,0 +1,28 @@ +# Main class +# TODO: http://symfony.com/doc/current/book/installation.html +# +# After provisioning, you'll probably just want to access http://localhost:PORT/config.php +# After configuration, start navigating at http://localhost:PORT/app_dev.php/ +class symfony { + include php + include database + include nodo::utils::web + include websites + + # Symfony requirement + file { '/etc/php5/conf.d/timezone.ini': + ensure => present, + owner => root, + group => root, + mode => 0644, + content => "date.timezone = America/Sao_Paulo\n", + notify => Service['apache'], + } +} + +# +# Class instantiations +# +class { 'symfony': + stage => main, +} |