Switch overcloud to software-config
[apex-tripleo-heat-templates.git] / block-storage.yaml
1 HeatTemplateFormatVersion: '2012-12-12'
2 Description: 'Common Block Storage Configuration'
3 Parameters:
4   BlockStorageImage:
5     Type: String
6     Default: overcloud-cinder-volume
7   OvercloudBlockStorageFlavor:
8     Default: baremetal
9     Description: Flavor for block storage nodes to request when deploying.
10     Type: String
11   NeutronNetworkType:
12     Type: String
13     Default: 'gre'
14   NeutronEnableTunnelling:
15     Type: String
16     Default: True
17 Resources:
18   BlockStorage0:
19     Type: OS::Nova::Server
20     Properties:
21       image:
22         {Ref: BlockStorageImage}
23       flavor: {Ref: OvercloudBlockStorageFlavor}
24       key_name: {Ref: KeyName}
25   BlockStorage0Deployment:
26     Type: OS::Heat::StructuredDeployment
27     Properties:
28       server: {Ref: BlockStorage0}
29       config: {Ref: BlockStorageConfig}
30       input_values:
31         controller_host: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [controller0, networks]} ]} ] }
32         cinder_dsn: {"Fn::Join": ['', ['mysql://cinder:unset@', {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [controller0, networks]} ]} ] } , '/cinder']]}
33         neutron_local_ip: {"Fn::Select": [0, "Fn::Select": [ctlplane, [{"Fn::GetAtt": [BlockStorage0 , networks]}]]]}
34   BlockStorageConfig:
35     Type: OS::Heat::StructuredConfig
36     Properties:
37       config:
38         admin-password: {Ref: AdminPassword}
39         keystone:
40           host: {get_input: controller_host}
41         cinder:
42           db: {get_input: cinder_dsn}
43           volume_size_mb: '5000'
44           service-password:
45             Ref: CinderPassword
46           iscsi-helper:
47             Ref: CinderISCSIHelper
48         admin-password: {Ref: AdminPassword}
49         rabbit:
50           host: {get_input: controller_host}
51           username: {Ref: RabbitUserName}
52           password: {Ref: RabbitPassword}
53         interfaces:
54           control: {Ref: NeutronPublicInterface}
55         neutron:
56           ovs:
57             local_ip: {get_input: neutron_local_ip}
58             tenant_network_type: {Ref: NeutronNetworkType}
59             enable_tunneling: {Ref: NeutronEnableTunnelling}
60           service-password:
61             Ref: NeutronPassword
62         config:
63           keystone:
64             host: {get_input: controller_host}
65           cinder:
66             db: {get_input: cinder_dsn}
67             volume_size_mb: '5000'
68             service-password:
69               Ref: CinderPassword
70             iscsi-helper:
71               Ref: CinderISCSIHelper
72           admin-password: {Ref: AdminPassword}
73           rabbit:
74             host: {get_input: controller_host}
75             username: {Ref: RabbitUserName}
76             password: {Ref: RabbitPassword}
77           interfaces:
78             control: {Ref: NeutronPublicInterface}
79           neutron:
80             ovs:
81               local_ip: { get_input: neutron_local_ip }
82               tenant_network_type: {Ref: NeutronNetworkType}
83               enable_tunneling: {Ref: NeutronEnableTunnelling}
84             service-password:
85               Ref: NeutronPassword