blob: e0f4b367b88edb02cb41804b2214481e4783b65d [file] [log] [blame]
Woojoong Kimaeb14f42017-10-18 09:42:25 -07001{#
2Copyright 2017-present Open Networking Foundation
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15#}
16
17
18tosca_definitions_version: tosca_simple_yaml_1_0
19
20description: created by platform-install, need to add M-CORD services later
21
22imports:
23 - custom_types/xos.yaml
Andy Bavieree0c91b2017-10-19 13:05:39 -070024 - custom_types/slice.yaml
25 - custom_types/site.yaml
26 - custom_types/image.yaml
27 - custom_types/flavor.yaml
28 - custom_types/network.yaml
29 - custom_types/networkslice.yaml
30 - custom_types/sdncontrollerservice.yaml
31 - custom_types/sdncontrollervendor.yaml
32 - custom_types/sdncontrollerserviceinstance.yaml
Woojoong Kimaeb14f42017-10-18 09:42:25 -070033
34topology_template:
35 node_templates:
36
37# site, image, fully created in deployment.yaml
38 {{ site_name }}:
39 type: tosca.nodes.Site
Andy Bavieree0c91b2017-10-19 13:05:39 -070040 properties:
41 must-exist: true
42 name: {{ site_name }}
Woojoong Kimaeb14f42017-10-18 09:42:25 -070043
44 m1.small:
45 type: tosca.nodes.Flavor
Andy Bavieree0c91b2017-10-19 13:05:39 -070046 properties:
47 name: m1.small
48 must-exist: true
Woojoong Kimaeb14f42017-10-18 09:42:25 -070049
50 trusty-server-multi-nic:
51 type: tosca.nodes.Image
Andy Bavieree0c91b2017-10-19 13:05:39 -070052 properties:
53 name: trusty-server-multi-nic
54 must-exist: true
Woojoong Kimaeb14f42017-10-18 09:42:25 -070055
56# management networks, fully created in management-net.yaml
57 management:
Andy Bavieree0c91b2017-10-19 13:05:39 -070058 type: tosca.nodes.Network
Woojoong Kimaeb14f42017-10-18 09:42:25 -070059 properties:
Andy Bavieree0c91b2017-10-19 13:05:39 -070060 must-exist: true
61 name: management
Woojoong Kimaeb14f42017-10-18 09:42:25 -070062
63{% if use_management_hosts %}
64 management_hosts:
Andy Bavieree0c91b2017-10-19 13:05:39 -070065 type: tosca.nodes.Network
Woojoong Kimaeb14f42017-10-18 09:42:25 -070066 properties:
Andy Bavieree0c91b2017-10-19 13:05:39 -070067 must-exist: true
68 name: management_hosts
Woojoong Kimaeb14f42017-10-18 09:42:25 -070069{% endif %}
70
Andy Bavieree0c91b2017-10-19 13:05:39 -070071# sbi_network is for connectivity between VMs, fully created in sbi-net.yaml
Woojoong Kimaeb14f42017-10-18 09:42:25 -070072 sbi_network:
Andy Bavieree0c91b2017-10-19 13:05:39 -070073 type: tosca.nodes.Network
Woojoong Kimaeb14f42017-10-18 09:42:25 -070074 properties:
Andy Bavieree0c91b2017-10-19 13:05:39 -070075 must-exist: true
76 name: sbi_network
Woojoong Kimaeb14f42017-10-18 09:42:25 -070077
Andy Bavieree0c91b2017-10-19 13:05:39 -070078# nbi_network is for connectivity between VMs, fully created in nbi-net.yaml
Woojoong Kimaeb14f42017-10-18 09:42:25 -070079 nbi_network:
Andy Bavieree0c91b2017-10-19 13:05:39 -070080 type: tosca.nodes.Network
Woojoong Kimaeb14f42017-10-18 09:42:25 -070081 properties:
Andy Bavieree0c91b2017-10-19 13:05:39 -070082 must-exist: true
83 name: nbi_network
Woojoong Kimaeb14f42017-10-18 09:42:25 -070084
85
86# CORD Services
87 service#sdncontroller:
88 type: tosca.nodes.SDNControllerService
89 properties:
Andy Bavieree0c91b2017-10-19 13:05:39 -070090 name: sdncontroller
91 public_key: {{ lookup('file', config_cord_profile_dir + '/key_import/mcord_rsa.pub') }}
Woojoong Kimaeb14f42017-10-18 09:42:25 -070092 private_key_fn: /opt/xos/services/sdncontroller/keys/mcord_rsa
93 artifacts:
94 pubkey: /opt/cord_profile/key_import/mcord_rsa.pub
95
96# CORD Slices
97 {{ site_name }}_sdncontroller:
98 description: SDN controller slice
99 type: tosca.nodes.Slice
100 properties:
Andy Bavieree0c91b2017-10-19 13:05:39 -0700101 name: {{ site_name }}_sdncontroller
102 default_isolation: vm
Woojoong Kimaeb14f42017-10-18 09:42:25 -0700103 network: noauto
104 requirements:
105 - site:
106 node: mysite
Andy Bavieree0c91b2017-10-19 13:05:39 -0700107 relationship: tosca.relationships.BelongsToOne
108 - service:
Woojoong Kimaeb14f42017-10-18 09:42:25 -0700109 node: service#sdncontroller
Andy Bavieree0c91b2017-10-19 13:05:39 -0700110 relationship: tosca.relationships.BelongsToOne
Woojoong Kimaeb14f42017-10-18 09:42:25 -0700111 - default_image:
112 node: trusty-server-multi-nic
Andy Bavieree0c91b2017-10-19 13:05:39 -0700113 relationship: tosca.relationships.BelongsToOne
Woojoong Kimaeb14f42017-10-18 09:42:25 -0700114 - default_flavor:
115 node: m1.small
Andy Bavieree0c91b2017-10-19 13:05:39 -0700116 relationship: tosca.relationships.BelongsToOne
117
118# CORD Service Instances
119
120 intel_sdncontroller:
121 type: tosca.nodes.SDNControllerVendor
122 properties:
123 name: intel_sdncontroller
124 requirements:
125 - image:
126 node: trusty-server-multi-nic
127 relationship: tosca.relationships.BelongsToOne
128 - flavor:
129 node: m1.small
130 relationship: tosca.relationships.BelongsToOne
131
132 serviceinstance#sdncontroller_instance:
133 type: tosca.nodes.SDNControllerServiceInstance
134 properties:
135 name: sdncontroller_instance1
136 requirements:
137 - sdncontroller_vendor:
138 node: intel_sdncontroller
139 relationship: tosca.relationships.BelongsToOne
140 - owner:
141 node: service#sdncontroller
142 relationship: tosca.relationships.BelongsToOne
143
144# CORD NetworkSlices
145 sdncontroller_slice_management_network:
146 type: tosca.nodes.NetworkSlice
147 requirements:
148 - network:
149 node: management
150 relationship: tosca.relationships.BelongsToOne
151 - slice:
152 node: {{ site_name }}_sdncontroller
153 relationship: tosca.relationships.BelongsToOne
154
155 sdncontroller_slice_sbi_network:
156 type: tosca.nodes.NetworkSlice
157 requirements:
158 - network:
159 node: sbi_network
160 relationship: tosca.relationships.BelongsToOne
161 - slice:
162 node: {{ site_name }}_sdncontroller
163 relationship: tosca.relationships.BelongsToOne
164
165 sdncontroller_slice_nbi_network:
166 type: tosca.nodes.NetworkSlice
167 requirements:
168 - network:
169 node: nbi_network
170 relationship: tosca.relationships.BelongsToOne
171 - slice:
172 node: {{ site_name }}_sdncontroller
173 relationship: tosca.relationships.BelongsToOne