2023-02-13 10:44:56 +01:00
|
|
|
# A Class using the db resurce
|
|
|
|
class sunetdrive::mariadb (
|
|
|
|
$bootstrap = undef,
|
|
|
|
$location = undef,
|
|
|
|
$tag_mariadb = undef,
|
|
|
|
$override_config = undef,
|
2023-06-12 09:31:41 +02:00
|
|
|
$override_compose = undef,
|
2023-02-13 10:44:56 +01:00
|
|
|
) {
|
|
|
|
|
2023-06-13 12:16:55 +02:00
|
|
|
$quorum_id = $facts['networking']['fqdn']
|
2023-02-13 10:44:56 +01:00
|
|
|
$quorum_password = safe_hiera('quorum_password')
|
|
|
|
$db = sunetdrive::db_type { 'base_db':
|
2024-10-09 14:25:34 +02:00
|
|
|
bootstrap => $bootstrap,
|
|
|
|
tag_mariadb => $tag_mariadb,
|
|
|
|
location => $location,
|
2023-02-13 10:44:56 +01:00
|
|
|
}
|
|
|
|
file { '/etc/quorum.conf':
|
|
|
|
ensure => file,
|
|
|
|
mode => '0644',
|
|
|
|
content => template('sunetdrive/mariadb/quorum.conf.erb'),
|
|
|
|
}
|
|
|
|
file { '/usr/local/bin/quorum':
|
|
|
|
ensure => file,
|
|
|
|
mode => '0700',
|
|
|
|
content => template('sunetdrive/mariadb/quorum.erb.sh'),
|
|
|
|
}
|
|
|
|
}
|