Puppet Class: cubbystack::glance::cache
- Defined in:
- manifests/glance/cache.pp
Overview
Class: cubbystack::glance::cache
Configures the glance-cache.conf file
Parameters
- settings
-
A hash of key => value settings to go in glance-cache.conf
- service_enable
-
The status of the glance-cache service Defaults to true
- config_file
-
The path to glance-cache.conf Defaults to /etc/glance/glance-cache.conf.
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'manifests/glance/cache.pp', line 18
class cubbystack::glance::cache (
$settings,
$config_file = '/etc/glance/glance-cache.conf',
) {
include ::cubbystack::params
## Meta settings and globals
$tags = ['openstack', 'glance', 'glance-cache']
# Make sure Glance is installed before any configuration happens
Package['glance'] -> Cubbystack_config<| tag == 'glance-cache' |>
File {
ensure => present,
owner => 'glance',
group => 'glance',
mode => '0640',
tag => $tags,
require => Package['glance'],
}
## Glance cache configuration
file { $config_file: }
# Configure the Cache service
$settings.each |$setting, $value| {
cubbystack_config { "${config_file}: ${setting}":
value => $value,
tag => $tags,
}
}
}
|