9f74110cb6
This patch upgrades the mysql module version as well as upgrading the usage of that module in openstack_project. This includes: - upgrading the syntax to set the root password - no longer setting bind_address anywhere since it defaults to 127.0.0.1 - upgrading the syntax to set the default storage engine using the new override_options param - upgrading the database and database_grant puppet resources to use the mysql_database and mysql_grant types. These types were renamed and are now more strict about how the title should look and what parameters need to be specified rather than inferred from the title. There is also no longer any reason to specify the 'mysql' provider since they gave up on the generic database provider idea. Changes to the system that we can expect: - /etc/mysql/my.cnf will have its parameters reordered. The key_buffer config parameter was renamed to key_buffer_size and the log_error parameter was renamed to log-error. Default values haven't changed. - The change in /etc/mysql/my.conf will trigger a mysql restart - /root/.my.cnf now adds single quotes around the password value. This won't change how mysql or the module reads the value, but puppet will report the file as having changed. This patch should not be merged until a downtime is prepared for the paste and wiki services. Change-Id: I8072e0aab03606307505e37fe6fb0c8b18eef854 Depends-On: I3ff754b15eef51c3c86c188647353a4a1d3bfea0
72 lines
1.8 KiB
Puppet
72 lines
1.8 KiB
Puppet
# == Class: openstack_project::wiki
|
|
#
|
|
class openstack_project::wiki (
|
|
$mysql_root_password = '',
|
|
$sysadmins = [],
|
|
$ssl_cert_file_contents = '',
|
|
$ssl_key_file_contents = '',
|
|
$ssl_chain_file_contents = ''
|
|
) {
|
|
|
|
package { ['openssl', 'ssl-cert', 'subversion']:
|
|
ensure => present;
|
|
}
|
|
|
|
class { 'openstack_project::server':
|
|
iptables_public_tcp_ports => [80, 443],
|
|
sysadmins => $sysadmins,
|
|
}
|
|
|
|
realize (
|
|
User::Virtual::Localuser['rlane'],
|
|
)
|
|
|
|
class { 'mediawiki':
|
|
role => 'all',
|
|
mediawiki_location => '/srv/mediawiki/w',
|
|
mediawiki_images_location => '/srv/mediawiki/images',
|
|
site_hostname => $::fqdn,
|
|
ssl_cert_file => "/etc/ssl/certs/${::fqdn}.pem",
|
|
ssl_key_file => "/etc/ssl/private/${::fqdn}.key",
|
|
ssl_chain_file => '/etc/ssl/certs/intermediate.pem',
|
|
ssl_cert_file_contents => $ssl_cert_file_contents,
|
|
ssl_key_file_contents => $ssl_key_file_contents,
|
|
ssl_chain_file_contents => $ssl_chain_file_contents,
|
|
}
|
|
class { 'memcached':
|
|
max_memory => 2048,
|
|
listen_ip => '127.0.0.1',
|
|
tcp_port => 11000,
|
|
udp_port => 11000,
|
|
}
|
|
class { 'mysql::server':
|
|
root_password => $mysql_root_password,
|
|
override_options => {
|
|
'mysqld' => {
|
|
'default-storage-engine' => 'InnoDB',
|
|
}
|
|
},
|
|
}
|
|
include mysql::server::account_security
|
|
|
|
mysql_backup::backup { 'wiki':
|
|
require => Class['mysql::server'],
|
|
}
|
|
|
|
include bup
|
|
bup::site { 'rs-ord':
|
|
backup_user => 'bup-wiki',
|
|
backup_server => 'ci-backup-rs-ord.openstack.org',
|
|
}
|
|
|
|
class { '::elasticsearch':
|
|
es_template_config => {
|
|
'bootstrap.mlockall' => true,
|
|
'discovery.zen.ping.unicast.hosts' => ['localhost'],
|
|
},
|
|
version => '1.3.2',
|
|
heap_size => '1g',
|
|
}
|
|
|
|
}
|