Commit 191c4373 authored by Matthieu FAURE's avatar Matthieu FAURE

REFACTOR Place MariaDB actions in the mariadb class

parent 26f1dd30
......@@ -115,26 +115,7 @@ class nextcloud (
# Install MariaDB
if $manage_mariadb {
# Install server + client + bindings
class { 'mysql::server':
package_name => 'mariadb-server',
root_password => $db_root_password,
remove_default_accounts => true,
}
class { 'mysql::client':
package_name => 'mariadb-client'
}
class { 'mysql::bindings':
php_enable => true,
}
# Create database for Nextcloud
mysql::db { $db_database_name:
user => $db_username,
password => $db_password,
host => $db_hostname,
grant => ['ALL'],
}
include nextcloud::mariadb
}
# Create NextCloud directory
......
# @summary Install Mariadb and create database
#
# Install Mariadb and create database
#
# @example
# include nextcloud::mariadb
class nextcloud::mariadb {
# Install server + client + bindings
class { 'mysql::server':
package_name => 'mariadb-server',
root_password => $nextcloud::db_root_password,
remove_default_accounts => true,
}
class { 'mysql::client':
package_name => 'mariadb-client'
}
class { 'mysql::bindings':
php_enable => true,
}
# Create database for Nextcloud
mysql::db { $nextcloud::db_database_name:
user => $nextcloud::db_username,
password => $nextcloud::db_password,
host => $nextcloud::db_hostname,
grant => ['ALL'],
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment