File: glance.pp

package info (click to toggle)
puppet-module-nova 25.0.0-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 4,100 kB
  • sloc: ruby: 11,433; python: 38; sh: 10; makefile: 10
file content (71 lines) | stat: -rw-r--r-- 2,586 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# == Class: nova::glance
#
# Configure usage of the glance service in nova
#
# === Parameters
#
# [*endpoint_override*]
#   (optional) Override the endpoint to use to talk to Glance.
#   Defaults to $facts['os_service_default']
#
# [*valid_interfaces*]
#   (optional) List of interfaces, in order of preference.
#   Defaults to $facts['os_service_default']
#
# [*num_retries*]
#   (optional) Number of retries in glance operation
#   Defaults to $facts['os_service_default']
#
# [*verify_glance_signatures*]
#   (optional) Whether to verify image signatures. (boolean value)
#   Defaults to $facts['os_service_default']
#
# [*enable_rbd_download*]
#   (optional) Enable download of Glance images directly via RBD
#   Defaults to $facts['os_service_default']
#
# [*rbd_user*]
#   (optional) The RADOS client name for accessing Glance images stored as
#   rbd volumes.
#   Defaults to $facts['os_service_default']
#
# [*rbd_connect_timeout*]
#   (optional) THe RADOS client timeout in seconds when initially connecting
#   to the cluster.
#   Defaults to $facts['os_service_default']
#
# [*rbd_pool*]
#   (optional) The RADOS pool in which the Glance images are stored as rbd
#   volumes.
#   Defaults to $facts['os_service_default']
#
# [*rbd_ceph_conf*]
#   (optional) Path to the ceph configuration file to use.
#   Defaults to $facts['os_service_default']
#
class nova::glance (
  $endpoint_override        = $facts['os_service_default'],
  $valid_interfaces         = $facts['os_service_default'],
  $num_retries              = $facts['os_service_default'],
  $verify_glance_signatures = $facts['os_service_default'],
  $enable_rbd_download      = $facts['os_service_default'],
  $rbd_user                 = $facts['os_service_default'],
  $rbd_connect_timeout      = $facts['os_service_default'],
  $rbd_pool                 = $facts['os_service_default'],
  $rbd_ceph_conf            = $facts['os_service_default'],
) {

  include nova::deps

  nova_config {
    'glance/endpoint_override':        value => $endpoint_override;
    'glance/valid_interfaces':         value => join(any2array($valid_interfaces), ',');
    'glance/num_retries':              value => $num_retries;
    'glance/verify_glance_signatures': value => $verify_glance_signatures;
    'glance/enable_rbd_download':      value => $enable_rbd_download;
    'glance/rbd_user':                 value => $rbd_user;
    'glance/rbd_connect_timeout':      value => $rbd_connect_timeout;
    'glance/rbd_pool':                 value => $rbd_pool;
    'glance/rbd_ceph_conf':            value => $rbd_ceph_conf;
  }
}