summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authormh <mh@immerda.ch>2015-01-24 18:05:08 +0100
committermh <mh@immerda.ch>2015-01-24 18:05:08 +0100
commite1649647f326abeb256a73e4cb1060840f846f24 (patch)
tree28ce305f242f98022d5c87280979230129854eec /manifests
parentfd71b9473fcb4c4e9f839bd9e579e899d424b71f (diff)
fix issues for EL7 + simplify account security
* EL7 uses mariadb & systemd -> adjust setpasswd script to that * move the security ensurance to the setpassword script, as it's easier to ensure that there
Diffstat (limited to 'manifests')
-rw-r--r--manifests/server/account_security.pp8
-rw-r--r--manifests/server/base.pp15
2 files changed, 6 insertions, 17 deletions
diff --git a/manifests/server/account_security.pp b/manifests/server/account_security.pp
deleted file mode 100644
index a17f0b3..0000000
--- a/manifests/server/account_security.pp
+++ /dev/null
@@ -1,8 +0,0 @@
-# some installations have some default users which are not required.
-# We remove them here. You can subclass this class to overwrite this behavior.
-class mysql::server::account_security {
- mysql_user{ [ "root@${::fqdn}", 'root@127.0.0.1', "@${::fqdn}", '@localhost', '@%' ]:
- ensure => 'absent',
- require => Exec['mysql_set_rootpw'],
- }
-}
diff --git a/manifests/server/base.pp b/manifests/server/base.pp
index 1ed75f2..0863950 100644
--- a/manifests/server/base.pp
+++ b/manifests/server/base.pp
@@ -33,7 +33,8 @@ class mysql::server::base {
mode => '0755';
'mysql_setmysqlpass.sh':
path => '/usr/local/sbin/setmysqlpass.sh',
- source => "puppet:///modules/mysql/scripts/${::operatingsystem}/setmysqlpass.sh",
+ source => ["puppet:///modules/mysql/scripts/${::operatingsystem}/setmysqlpass.sh.${::operatingsystemmajrelease}",
+ "puppet:///modules/mysql/scripts/${::operatingsystem}/setmysqlpass.sh", ],
require => Package['mysql-server'],
owner => root,
group => 0,
@@ -72,12 +73,8 @@ class mysql::server::base {
require => Package['mysql-server'],
}
- if str2bool($::mysql_exists) {
- include mysql::server::account_security
-
- # Collect all databases and users
- Mysql_database<<| tag == "mysql_${::fqdn}" |>>
- Mysql_user<<| tag == "mysql_${::fqdn}" |>>
- Mysql_grant<<| tag == "mysql_${::fqdn}" |>>
- }
+ # Collect all databases and users
+ Mysql_database<<| tag == "mysql_${::fqdn}" |>>
+ Mysql_user<<| tag == "mysql_${::fqdn}" |>>
+ Mysql_grant<<| tag == "mysql_${::fqdn}" |>>
}