blob: 0159abe4e5e90cc5628ad846c6d18ec8990924ae [file] [log] [blame]
Matteo Scandolo3896c472017-08-01 13:31:42 -07001
2{#
3Copyright 2017-present Open Networking Foundation
4
5Licensed under the Apache License, Version 2.0 (the "License");
6you may not use this file except in compliance with the License.
7You may obtain a copy of the License at
8
9http://www.apache.org/licenses/LICENSE-2.0
10
11Unless required by applicable law or agreed to in writing, software
12distributed under the License is distributed on an "AS IS" BASIS,
13WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14See the License for the specific language governing permissions and
15limitations under the License.
16#}
17
18
Zack Williams682450e2016-11-19 09:04:41 -070019tosca_definitions_version: tosca_simple_yaml_1_0
20
21imports:
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080022 - custom_types/controller.yaml
23 - custom_types/controllersite.yaml
24 - custom_types/deployment.yaml
25 - custom_types/flavor.yaml
26 - custom_types/image.yaml
27 - custom_types/site.yaml
28 - custom_types/sitedeployment.yaml
Zack Williams682450e2016-11-19 09:04:41 -070029
30description: openstack extensions to deployment, generated by platform-install
31
32topology_template:
33 node_templates:
34
35# Images and flavors
36{% for image in xos_images %}
37 {{ image.name }}:
38 type: tosca.nodes.Image
39 properties:
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080040 name: {{ image.name }}
41 path: /opt/xos/images/{{ image.name }}.qcow2
42 disk_format: QCOW2
43 container_format: BARE
Zack Williams682450e2016-11-19 09:04:41 -070044
45{% endfor %}
46
47{% for flavor in deployment_flavors %}
48 {{ flavor }}:
49 type: tosca.nodes.Flavor
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080050 properties:
51 name: {{ flavor }}
Zack Williams682450e2016-11-19 09:04:41 -070052
53{% endfor %}
54
55# Deployment - adds images/flavors to site defined in deployment.yaml
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080056# NOTE do we still need this?
Zack Williams682450e2016-11-19 09:04:41 -070057 {{ deployment_type }}:
58 type: tosca.nodes.Deployment
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080059 properties:
60 name: {{ deployment_type }}
61# NOTE look that this are outdated and not used anymore
62# requirements:
63# {% for flavor in deployment_flavors %}
64# - {{ flavor }}:
65# node: {{ flavor }}
66# relationship: tosca.relationships.SupportsFlavor
67# {% endfor %}
Zack Williams682450e2016-11-19 09:04:41 -070068
69# OpenStack Controller
70 {{ site_name }}_{{ deployment_type }}_openstack:
71 type: tosca.nodes.Controller
72 requirements:
73 - deployment:
74 node: {{ deployment_type }}
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080075 relationship: tosca.relationships.BelongsToOne
Zack Williams682450e2016-11-19 09:04:41 -070076 properties:
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080077 name: {{ site_name }}_{{ deployment_type }}_openstack
Zack Williams682450e2016-11-19 09:04:41 -070078 backend_type: OpenStack
79 version: Kilo
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080080 auth_url: https://keystone.{{ site_suffix }}:5000/v2.0
81 admin_user: admin
82 admin_password: {{ keystone_admin_password }}
83 admin_tenant: admin
Zack Williams682450e2016-11-19 09:04:41 -070084 domain: Default
85 artifacts:
Zack Williamsa2763112017-01-03 11:38:38 -070086 adminrc: /opt/cord_profile/admin-openrc.sh
Zack Williams682450e2016-11-19 09:04:41 -070087
88# Site - adds openstack controller to site defined in deployment.yaml
89 {{ site_name }}:
90 type: tosca.nodes.Site
91 properties:
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080092 name: {{ site_name }}
93 must-exist: true
Zack Williams682450e2016-11-19 09:04:41 -070094 site_url: http://{{ site_name }}.opencloud.us/
95 hosts_nodes: true
Matteo Scandolo1ed76b82017-12-05 13:58:22 -080096
97 {{site_name}}_deployment_{{ deployment_type }}:
98 type: tosca.nodes.SiteDeployment
99 requirements:
100 - site:
101 node: {{ site_name }}
102 relationship: tosca.relationships.BelongsToOne
103 - deployment:
104 node: {{ deployment_type }}
105 relationship: tosca.relationships.BelongsToOne
106 - controller:
107 node: {{ site_name }}_{{ deployment_type }}_openstack
108 relationship: tosca.relationships.BelongsToOne
109
110 {{ site_name }}_openstack_controller:
111 type: tosca.nodes.ControllerSite
112 requirements:
113 - site:
114 node: {{ site_name }}
115 relationship: tosca.relationships.BelongsToOne
116 - controller:
117 node: {{ site_name }}_{{ deployment_type }}_openstack
118 relationship: tosca.relationships.BelongsToOne
Zack Williams682450e2016-11-19 09:04:41 -0700119