2505ba21464ac25f34c70bcb54e08e89b86b4095
[apex-tripleo-heat-templates.git] / overcloud-source.yaml
1 Description: Nova API,Keystone,Heat Engine and API,Glance,Neutron,Dedicated MySQL
2   server,Dedicated RabbitMQ Server,Group of Nova Computes
3 HeatTemplateFormatVersion: '2012-12-12'
4 Parameters:
5   AdminPassword:
6     Default: unset
7     Description: The password for the keystone admin account, used for monitoring, querying neutron etc.
8     Type: String
9   AdminToken:
10     Default: unset
11     Description: The keystone auth secret.
12     Type: String
13   CinderPassword:
14     Default: unset
15     Description: The password for the cinder service account, used by cinder-api.
16     Type: String
17   Flavor:
18     Default: baremetal
19     Description: Flavor to request when deploying.
20     Type: String
21   GlancePassword:
22     Default: unset
23     Description: The password for the glance service account, used by the glance services.
24     Type: String
25   KeyName:
26     Default: default
27     Description: Name of an existing EC2 KeyPair to enable SSH access to the instances
28     Type: String
29   NeutronPassword:
30     Default: unset
31     Description: The password for the neutron service account, used by neutron agents.
32     Type: String
33   NovaComputeDriver:
34     Default: libvirt.LibvirtDriver
35     Type: String
36   NovaComputeLibvirtType:
37     Default: ''
38     Type: String
39   NovaImage:
40     Type: String
41     Default: overcloud-compute
42   NovaInterfaces:
43     Default: eth0
44     Type: String
45   NovaPassword:
46     Default: unset
47     Description: The password for the nova service account, used by nova-api.
48     Type: String
49   PowerUserName:
50     Default: stack
51     Description: What username to ssh to the virtual power host with.
52     Type: String
53   notcomputeImage:
54     Type: String
55     Default: overcloud-control
56 Resources:
57   AccessPolicy:
58     Properties:
59       AllowedResources:
60       - notcompute
61       - notcomputeConfig
62     Type: OS::Heat::AccessPolicy
63   ComputeAccessPolicy:
64     Properties:
65       AllowedResources:
66       - NovaCompute0
67       - NovaCompute0Config
68     Type: OS::Heat::AccessPolicy
69   Key:
70     Properties:
71       UserName:
72         Ref: User
73     Type: AWS::IAM::AccessKey
74   ComputeKey:
75     Properties:
76       UserName:
77         Ref: ComputeUser
78     Type: AWS::IAM::AccessKey
79   ComputeUser:
80     Properties:
81       Policies:
82       - Ref: ComputeAccessPolicy
83     Type: AWS::IAM::User
84   NovaCompute0Config:
85     Type: FileInclude
86     Path: nova-compute-instance.yaml
87     SubKey: Resources.NovaCompute0Config
88     Parameters:
89         NovaApiHost: {"Fn::GetAtt": [notcompute, PrivateIp]}
90         KeystoneHost: {"Fn::GetAtt": [notcompute, PrivateIp]}
91         RabbitHost: {"Fn::GetAtt": [notcompute, PrivateIp]}
92         NeutronHost: {"Fn::GetAtt": [notcompute, PrivateIp]}
93         GlanceHost: {"Fn::GetAtt": [notcompute, PrivateIp]}
94         NovaDSN: {"Fn::Join": ['', ['mysql://nova:unset@', {"Fn::GetAtt": [notcompute, PrivateIp]}, '/nova']]}
95         NeutronDSN: {"Fn::Join": ['', ['mysql://neutron:unset@', {"Fn::GetAtt": [notcompute, PrivateIp]}, '/neutron']]}
96         NeutronNetworkType: "gre"
97         NeutronEnableTunnelling: "True"
98         NeutronNetworkVLANRanges: ""
99         NeutronBridgeMappings: ""
100         RabbitPassword: "guest"
101         ServicePassword: "unset"
102   NovaCompute0:
103     Type: FileInclude
104     Path: nova-compute-instance.yaml
105     SubKey: Resources.NovaCompute0
106   User:
107     Properties:
108       Policies:
109       - Ref: AccessPolicy
110     Type: AWS::IAM::User
111   notcomputeConfig:
112     Type: AWS::AutoScaling::LaunchConfiguration
113     Properties:
114       ImageId: '0'
115       InstanceType: '0'
116     Metadata:
117       OpenStack::Heat::Stack: {}
118       Openstack::ImageBuilder::Elements:
119       - boot-stack
120       - heat-cfntools
121       - heat-localip
122       - neutron-network-node
123       admin-password:
124         Ref: AdminPassword
125       admin-token:
126         Ref: AdminToken
127       cinder:
128         db: mysql://cinder:unset@localhost/cinder
129         volume_size_mb: '5000'
130         service-password:
131           Ref: CinderPassword
132       controller-address:
133         Fn::GetAtt:
134           - notcompute
135           - PrivateIp
136       db-password: unset
137       glance:
138         db: mysql://glance:unset@localhost/glance
139         host:
140           Fn::GetAtt:
141             - notcompute
142             - PrivateIp
143         service-password:
144           Ref: GlancePassword
145       os-collect-config:
146         cfn:
147           access_key_id:
148             Ref: Key
149           path: notcomputeConfig.Metadata
150           secret_access_key:
151             Fn::GetAtt:
152             - Key
153             - SecretAccessKey
154           stack_name:
155             Ref: AWS::StackName
156       heat:
157         admin_password: unset
158         admin_tenant_name: service
159         admin_user: heat
160         auth_encryption_key: unset___________
161         db: mysql://heat:unset@localhost/heat
162         heat_watch_server_url:
163           Fn::Join:
164             - ''
165             - - 'http://'
166               - Fn::GetAtt:
167                   - notcompute
168                   - PrivateIp
169               - ':8003'
170         metadata_server_url:
171           Fn::Join:
172             - ''
173             - - 'http://'
174               - Fn::GetAtt:
175                   - notcompute
176                   - PrivateIp
177               - ':8000'
178         waitcondition_server_url:
179           Fn::Join:
180             - ''
181             - - 'http://'
182               - Fn::GetAtt:
183                   - notcompute
184                   - PrivateIp
185               - ':8000/v1/waitcondition'
186       interfaces:
187         control: eth0
188       keystone:
189         db: mysql://keystone:unset@localhost/keystone
190         host:
191           Fn::GetAtt:
192             - notcompute
193             - PrivateIp
194       nova:
195         compute_driver: libvirt.LibvirtDriver
196         db: mysql://nova:unset@localhost/nova
197         host:
198           Fn::GetAtt:
199             - notcompute
200             - PrivateIp
201         metadata-proxy: true
202         service-password:
203           Ref: NovaPassword
204       neutron:
205         host:
206           Fn::GetAtt:
207             - notcompute
208             - PrivateIp
209         metadata_proxy_shared_secret: unset
210         ovs:
211           enable_tunneling: 'True'
212           local_ip:
213             Fn::GetAtt:
214               - notcompute
215               - PrivateIp
216           public_interface: eth0
217           physical_bridge: br-ex
218           tenant_network_type: gre
219         ovs_db: mysql://neutron:unset@localhost/ovs_neutron?charset=utf8
220         service-password:
221           Ref: NeutronPassword
222       rabbit:
223         host:
224           Fn::GetAtt:
225             - notcompute
226             - PrivateIp
227         password: guest
228       service-password: unset
229   notcompute:
230     Type: OS::Nova::Server
231     Properties:
232       image:
233         Ref: notcomputeImage
234       flavor:
235         Ref: Flavor
236       key_name:
237         Ref: KeyName
238     Metadata:
239       os-collect-config:
240         cfn:
241           access_key_id:
242             Ref: Key
243           path: notcomputeConfig.Metadata
244           secret_access_key:
245             Fn::GetAtt:
246             - Key
247             - SecretAccessKey
248           stack_name:
249             Ref: AWS::StackName