Merge "Update descriptions comments for Ceph params"
[apex-tripleo-heat-templates.git] / ceph-storage.yaml
1 heat_template_version: 2014-10-16
2 description: 'Common Ceph Storage Configuration'
3 parameters:
4   Image:
5     type: string
6     default: overcloud-ceph-storage
7   KeyName:
8     default: default
9     description: Name of an existing EC2 KeyPair to enable SSH access to the instances
10     type: string
11   Flavor:
12     default: baremetal
13     description: Flavor for block storage nodes to request when deploying.
14     type: string
15   CephClusterFSID:
16     default: ''
17     type: string
18     description: The Ceph cluster FSID. Must be a UUID.
19   CephMonKey:
20     default: ''
21     description: The Ceph monitors key. Can be created with ceph-authtool --gen-print-key.
22     type: string
23   CephAdminKey:
24     default: ''
25     description: The Ceph admin client key. Can be created with ceph-authtool --gen-print-key.
26     type: string
27   CephMonitors:
28     default: ''
29     description: The list of ip/names to use as Ceph monitors
30     type: json
31 resources:
32   CephStorage:
33     type: OS::Nova::Server
34     properties:
35       image:
36         {get_param: Image}
37       flavor: {get_param: OvercloudCephStorageFlavor}
38       key_name: {get_param: KeyName}
39       user_data_format: SOFTWARE_CONFIG
40       networks:
41         - network: ctlplane
42   CephStorageDeployment:
43     type: OS::Heat::StructuredDeployment
44     properties:
45       server: {get_resource: CephStorage}
46       config: {get_resource: CephStorageConfig}
47       signal_transport: NO_SIGNAL
48   CephStorageConfig:
49     type: OS::Heat::StructuredConfig
50     properties:
51       group: os-apply-config
52       config:
53         ceph:
54           fsid: {get_param: CephClusterFSID}
55           keyrings:
56             admin:
57               key: {get_param: CephAdminKey}
58           mon_nodes: {get_param: CephMonitors}
59   ControllerCephDeployment:
60     type: OS::Heat::StructuredDeployment
61     properties:
62       server: {get_resource: Controller}
63       config: {get_resource: ControllerCephConfig}
64       signal_transport: NO_SIGNAL
65   ControllerCephConfig:
66     type: OS::Heat::StructuredConfig
67     properties:
68       group: os-apply-config
69       config:
70         cinder:
71           include_ceph_backend: true
72         ceph:
73           fsid: {get_param: CephClusterFSID}
74           keyrings:
75             mon:
76               key: {get_param: CephMonKey}
77             admin:
78               key: {get_param: CephAdminKey}
79           mon_nodes: {get_param: CephMonitors}
80   NovaComputeCephDeployment:
81     depends_on: [ControllerCephDeployment]
82     type: OS::Heat::StructuredDeployment
83     properties:
84       server: {get_resource: NovaCompute}
85       config: {get_resource: NovaComputeCephConfig}
86       signal_transport: NO_SIGNAL
87   NovaComputeCephConfig:
88     type: OS::Heat::StructuredConfig
89     properties:
90       group: os-apply-config
91       config:
92         ceph:
93           fsid: {get_param: CephClusterFSID}
94           keyrings:
95             admin:
96               key: {get_param: CephAdminKey}
97           mon_nodes: {get_param: CephMonitors}
98 outputs:
99   hosts_entry:
100     value:
101       str_replace:
102         template: "IP HOST HOST.novalocal"
103         params:
104           IP: {get_attr: [CephStorage, networks, ctlplane, 0]}
105           HOST: {get_attr: [CephStorage, name]}