puppet-cinder/manifests/base.pp
Dan Bode 7d07f23914 update permission of paste config to 600
to ensure that any system users cannot read
credentials stored in the file.
2013-03-20 15:20:04 -07:00

63 lines
1.7 KiB
Puppet

#
# parameters that may need to be added
# $state_path = /opt/stack/data/cinder
# $osapi_volume_extension = cinder.api.openstack.volume.contrib.standard_extensions
# $root_helper = sudo /usr/local/bin/cinder-rootwrap /etc/cinder/rootwrap.conf
class cinder::base (
$rabbit_password,
$sql_connection,
$rabbit_host = '127.0.0.1',
$rabbit_port = 5672,
$rabbit_virtual_host = '/',
$rabbit_userid = 'nova',
$package_ensure = 'present',
$api_paste_config = '/etc/cinder/api-paste.ini',
$verbose = 'False'
) {
include cinder::params
Package['cinder'] -> Cinder_config<||>
Package['cinder'] -> Cinder_api_paste_ini<||>
package { 'cinder':
name => $::cinder::params::package_name,
ensure => $package_ensure,
}
File {
ensure => present,
owner => 'cinder',
group => 'cinder',
mode => '0644',
require => Package[$::cinder::params::package_name],
}
file { $::cinder::params::cinder_conf:
mode => '0600',
}
file { $::cinder::params::cinder_paste_api_ini:
mode => '0600',
}
# Temporary fixes
file { ['/var/log/cinder', '/var/lib/cinder']:
ensure => directory,
owner => 'cinder',
group => 'cinder',
}
cinder_config {
'DEFAULT/rabbit_password': value => $rabbit_password;
'DEFAULT/rabbit_host': value => $rabbit_host;
'DEFAULT/rabbit_port': value => $rabbit_port;
'DEFAULT/rabbit_virtual_host': value => $rabbit_virtual_host;
'DEFAULT/rabbit_userid': value => $rabbit_userid;
'DEFAULT/sql_connection': value => $sql_connection;
'DEFAULT/verbose': value => $verbose;
'DEFAULT/api_paste_config': value => $api_paste_config;
}
}