Merge "Remove LiveUpdate params"
[apex-tripleo-heat-templates.git] / cinder-storage.yaml
1 heat_template_version: 2014-10-16
2 description: 'Common Block Storage Configuration'
3 parameters:
4   AdminPassword:
5     default: ''
6     type: string
7   Image:
8     default: overcloud-cinder-volume
9     type: string
10   CinderISCSIHelper:
11     default: tgtadm
12     description: The iSCSI helper to use with cinder.
13     type: string
14   CinderLVMLoopDeviceSize:
15     default: 5000
16     description: The size of the loopback file used by the cinder LVM driver.
17     type: number
18   CinderPassword:
19     default: unset
20     description: The password for the cinder service account, used by cinder-api.
21     hidden: true
22     type: string
23   VirtualIP:
24     default: ''
25     type: string
26   ExtraConfig:
27     default: {}
28     description: |
29       Additional configuration to inject into the cluster. The JSON should have
30       the following structure:
31         {"FILEKEY":
32           {"config":
33             [{"section": "SECTIONNAME",
34               "values":
35                 [{"option": "OPTIONNAME",
36                   "value": "VALUENAME"
37                  }
38                 ]
39              }
40             ]
41           }
42         }
43       For instance:
44         {"nova":
45           {"config":
46             [{"section": "default",
47               "values":
48                 [{"option": "force_config_drive",
49                   "value": "always"
50                  }
51                 ]
52              },
53              {"section": "cells",
54               "values":
55                 [{"option": "driver",
56                   "value": "nova.cells.rpc_driver.CellsRPCDriver"
57                  }
58                 ]
59              }
60             ]
61           }
62         }
63     type: json
64   Flavor:
65     default: baremetal
66     description: Flavor for block storage nodes to request when deploying.
67     type: string
68   GlancePort:
69     default: "9292"
70     description: Glance port.
71     type: string
72   KeyName:
73     default: default
74     description: Name of an existing EC2 KeyPair to enable SSH access to the instances
75     type: string
76   RabbitPassword:
77     default: ''
78     type: string
79   RabbitUserName:
80     default: ''
81     type: string
82   SnmpdReadonlyUserName:
83     default: ro_snmp_user
84     description: The user name for SNMPd with readonly rights running on all Overcloud nodes
85     type: string
86   SnmpdReadonlyUserPassword:
87     default: unset
88     description: The user password for SNMPd with readonly rights running on all Overcloud nodes
89     type: string
90     hidden: true
91 resources:
92   BlockStorage:
93     type: OS::Nova::Server
94     properties:
95       image:
96         {get_param: Image}
97       flavor: {get_param: Flavor}
98       key_name: {get_param: KeyName}
99       user_data_format: SOFTWARE_CONFIG
100       networks:
101         - network: ctlplane
102   BlockStorageDeployment:
103     type: OS::Heat::StructuredDeployment
104     properties:
105       server: {get_resource: BlockStorage}
106       config: {get_resource: BlockStorageConfig}
107       input_values:
108         controller_virtual_ip: {get_param: VirtualIP}
109         cinder_dsn: {list_join: ['', ['mysql://cinder:unset@', {get_param: VirtualIP} , '/cinder']]}
110         snmpd_readonly_user_name: {get_param: SnmpdReadonlyUserName}
111         snmpd_readonly_user_password: {get_param: SnmpdReadonlyUserPassword}
112       signal_transport: NO_SIGNAL
113   BlockStorageConfig:
114     type: OS::Heat::StructuredConfig
115     properties:
116       group: os-apply-config
117       config:
118         admin-password: {get_param: AdminPassword}
119         keystone:
120           host: {get_input: controller_virtual_ip}
121         cinder:
122           db: {get_input: cinder_dsn}
123           volume_size_mb:
124             get_param: CinderLVMLoopDeviceSize
125           service-password:
126             get_param: CinderPassword
127           iscsi-helper:
128             get_param: CinderISCSIHelper
129         snmpd:
130           export_MIB: UCD-SNMP-MIB
131           readonly_user_name: {get_input: snmpd_readonly_user_name}
132           readonly_user_password: {get_input: snmpd_readonly_user_password}
133         rabbit:
134           host: {get_input: controller_virtual_ip}
135           username: {get_param: RabbitUserName}
136           password: {get_param: RabbitPassword}
137         glance:
138           host: {get_input: controller_virtual_ip}
139           port: {get_param: GlancePort}
140 outputs:
141   hosts_entry:
142     value:
143       str_replace:
144         template: "IP HOST HOST.novalocal"
145         params:
146           IP: {get_attr: [BlockStorage, networks, ctlplane, 0]}
147           HOST: {get_attr: [BlockStorage, name]}