a787cd9486f46b526cfd2e9c667898be6545ae9b
[mirror/dsa-puppet.git] / 3rdparty / modules / cinder / manifests / volume / san.pp
1 # == Class: cinder::volume::san
2 #
3 # Configures Cinder volume SAN driver.
4 # Parameters are particular to each volume driver.
5 #
6 # === Parameters
7 #
8 # [*volume_driver*]
9 #   (required) Setup cinder-volume to use volume driver.
10 #
11 # [*san_thin_provision*]
12 #   (optional) Use thin provisioning for SAN volumes? Defaults to true.
13 #
14 # [*san_ip*]
15 #   (optional) IP address of SAN controller.
16 #
17 # [*san_login*]
18 #   (optional) Username for SAN controller. Defaults to 'admin'.
19 #
20 # [*san_password*]
21 #   (optional) Password for SAN controller.
22 #
23 # [*san_private_key*]
24 #   (optional) Filename of private key to use for SSH authentication.
25 #
26 # [*san_clustername*]
27 #   (optional) Cluster name to use for creating volumes.
28 #
29 # [*san_ssh_port*]
30 #   (optional) SSH port to use with SAN. Defaults to 22.
31 #
32 # [*san_is_local*]
33 #   (optional) Execute commands locally instead of over SSH
34 #   use if the volume service is running on the SAN device.
35 #
36 # [*ssh_conn_timeout*]
37 #   (optional) SSH connection timeout in seconds. Defaults to 30.
38 #
39 # [*ssh_min_pool_conn*]
40 #   (optional) Minimum ssh connections in the pool.
41 #
42 # [*ssh_min_pool_conn*]
43 #   (optional) Maximum ssh connections in the pool.
44 #
45 class cinder::volume::san (
46   $volume_driver,
47   $san_thin_provision = true,
48   $san_ip             = undef,
49   $san_login          = 'admin',
50   $san_password       = undef,
51   $san_private_key    = undef,
52   $san_clustername    = undef,
53   $san_ssh_port       = 22,
54   $san_is_local       = false,
55   $ssh_conn_timeout   = 30,
56   $ssh_min_pool_conn  = 1,
57   $ssh_max_pool_conn  = 5
58 ) {
59
60   cinder::backend::san { 'DEFAULT':
61     volume_driver      => $volume_driver,
62     san_thin_provision => $san_thin_provision,
63     san_ip             => $san_ip,
64     san_login          => $san_login,
65     san_password       => $san_password,
66     san_private_key    => $san_private_key,
67     san_clustername    => $san_clustername,
68     san_ssh_port       => $san_ssh_port,
69     san_is_local       => $san_is_local,
70     ssh_conn_timeout   => $ssh_conn_timeout,
71     ssh_min_pool_conn  => $ssh_min_pool_conn,
72     ssh_max_pool_conn  => $ssh_max_pool_conn,
73   }
74 }