Mercurial > repos > other > Puppet
diff manifests/templates.pp @ 24:204330fea19a puppet-3.6
Use MariaDB on CentOS7 and manage hiera.yaml (to avoid warnings)
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Mon, 09 Mar 2015 00:01:27 +0000 |
parents | ed5edb4c9412 |
children | 13adb555a7e2 |
line wrap: on
line diff
--- a/manifests/templates.pp Sun Mar 08 23:58:22 2015 +0000 +++ b/manifests/templates.pp Mon Mar 09 00:01:27 2015 +0000 @@ -5,6 +5,16 @@ include defaultusers include logwatch + + file { '/etc/puppet/hiera.yaml': + ensure => present, + content => "--- +:backends: yaml +:yaml: + :datadir: /var/lib/hiera +:hierarchy: common +:logger: console", + } } class basevpsnode ( @@ -223,11 +233,22 @@ suffix => '55ibb', #IBBoard's rebuild of Webtatic's PHP 5.5 opcache => 'opcache', } + #Setup MySQL, using (private) templates to make sure that we set non-std passwords and a default user + + if $operatingsystem == 'CentOS' and versioncmp($operatingsystemrelease, 7) >= 0 { + $mysqlpackage = 'mariadb' + $mysqlsuffix = '' + } + else { + $mysqlpackage = 'mysql' + $mysqlsuffix = '55w' + } class { 'website::mysql': mysqluser => template('defaultusers/mysql-user'), mysqlpassword => template('defaultusers/mysql-password'), - mysqlsuffix => '55w', + mysqlprefix => $mysqlpackage, + mysqlsuffix => $mysqlsuffix, phpsuffix => '55ibb', phpmysqlsuffix => 'nd' }