memcached (openstack) is no longer in use
[mirror/dsa-puppet.git] / 3rdparty / modules / cinder / manifests / volume / rbd.pp
1 # == Class: cinder::volume::rbd
2 #
3 # Setup Cinder to use the RBD driver.
4 #
5 # === Parameters
6 #
7 # [*rbd_pool*]
8 #   (required) Specifies the pool name for the block device driver.
9 #
10 # [*rbd_user*]
11 #   (required) A required parameter to configure OS init scripts and cephx.
12 #
13 # [*rbd_ceph_conf*]
14 #   (optional) Path to the ceph configuration file to use
15 #   Defaults to '/etc/ceph/ceph.conf'
16 #
17 # [*rbd_flatten_volume_from_snapshot*]
18 #   (optional) Enable flatten volumes created from snapshots.
19 #   Defaults to false
20 #
21 # [*rbd_secret_uuid*]
22 #   (optional) A required parameter to use cephx.
23 #   Defaults to false
24 #
25 # [*volume_tmp_dir*]
26 #   (optional) Location to store temporary image files if the volume
27 #   driver does not write them directly to the volume
28 #   Defaults to false
29 #
30 # [*rbd_max_clone_depth*]
31 #   (optional) Maximum number of nested clones that can be taken of a
32 #   volume before enforcing a flatten prior to next clone.
33 #   A value of zero disables cloning
34 #   Defaults to '5'
35 #
36 # [*glance_api_version*]
37 #   (optional) DEPRECATED: Use cinder::glance Class instead.
38 #   Glance API version. (Defaults to '2')
39 #   Setting this parameter cause a duplicate resource declaration
40 #   with cinder::glance
41 #
42 class cinder::volume::rbd (
43   $rbd_pool,
44   $rbd_user,
45   $rbd_ceph_conf                    = '/etc/ceph/ceph.conf',
46   $rbd_flatten_volume_from_snapshot = false,
47   $rbd_secret_uuid                  = false,
48   $volume_tmp_dir                   = false,
49   $rbd_max_clone_depth              = '5',
50   # DEPRECATED PARAMETERS
51   $glance_api_version               = undef,
52 ) {
53
54   cinder::backend::rbd { 'DEFAULT':
55     rbd_pool                         => $rbd_pool,
56     rbd_user                         => $rbd_user,
57     rbd_ceph_conf                    => $rbd_ceph_conf,
58     rbd_flatten_volume_from_snapshot => $rbd_flatten_volume_from_snapshot,
59     rbd_secret_uuid                  => $rbd_secret_uuid,
60     volume_tmp_dir                   => $volume_tmp_dir,
61     rbd_max_clone_depth              => $rbd_max_clone_depth,
62     glance_api_version               => $glance_api_version,
63   }
64 }