Andy Bavier | c0aa0b9 | 2018-04-23 11:28:38 -0700 | [diff] [blame] | 1 | --- |
| 2 | # Copyright 2018-present Open Networking Foundation |
| 3 | # |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # You may obtain a copy of the License at |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | # See the License for the specific language governing permissions and |
| 14 | # limitations under the License. |
| 15 | |
| 16 | # Default values for the base-openstack profile. |
| 17 | # This is a YAML-formatted file. |
| 18 | # Declare variables to be passed into your templates. |
| 19 | |
| 20 | replicaCount: 1 |
| 21 | |
| 22 | nameOverride: "" |
| 23 | fullnameOverride: "" |
| 24 | |
Matteo Scandolo | e2965c9 | 2018-05-08 13:22:20 -0700 | [diff] [blame] | 25 | imagePullPolicy: 'Always' |
Andy Bavier | c0aa0b9 | 2018-04-23 11:28:38 -0700 | [diff] [blame] | 26 | |
| 27 | httpieImage: "clue/httpie:latest" |
| 28 | |
| 29 | xosAdminUser: &adminuser "admin@opencord.org" |
| 30 | xosAdminPassword: &adminpass "letmein" |
| 31 | |
| 32 | # TOSCA recipes for the tosca-loader |
| 33 | toscaRecipes: |
| 34 | openstack: |
| 35 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 36 | |
| 37 | imports: |
| 38 | - custom_types/controller.yaml |
| 39 | - custom_types/controllersite.yaml |
| 40 | - custom_types/deployment.yaml |
| 41 | - custom_types/flavor.yaml |
| 42 | - custom_types/image.yaml |
| 43 | - custom_types/site.yaml |
| 44 | - custom_types/networktemplate.yaml |
| 45 | - custom_types/network.yaml |
| 46 | - custom_types/networkslice.yaml |
| 47 | - custom_types/slice.yaml |
| 48 | - custom_types/sitedeployment.yaml |
| 49 | |
| 50 | description: openstack extensions to deployment |
| 51 | |
| 52 | topology_template: |
| 53 | node_templates: |
| 54 | |
| 55 | # Images and flavors |
| 56 | Ubuntu-14.04: |
| 57 | type: tosca.nodes.Image |
| 58 | properties: |
| 59 | name: "Ubuntu 14.04 64-bit" |
| 60 | disk_format: QCOW2 |
| 61 | container_format: BARE |
| 62 | path: https://github.com/opencord/platform-install/releases/download/vms/trusty-server-cloudimg-amd64-disk1.img.20170201 |
| 63 | |
| 64 | m1.tiny: |
| 65 | type: tosca.nodes.Flavor |
| 66 | properties: |
| 67 | name: m1.tiny |
| 68 | |
| 69 | m1.small: |
| 70 | type: tosca.nodes.Flavor |
| 71 | properties: |
| 72 | name: m1.small |
| 73 | |
| 74 | m1.medium: |
| 75 | type: tosca.nodes.Flavor |
| 76 | properties: |
| 77 | name: m1.medium |
| 78 | |
| 79 | m1.large: |
| 80 | type: tosca.nodes.Flavor |
| 81 | properties: |
| 82 | name: m1.large |
| 83 | |
| 84 | m1.xlarge: |
| 85 | type: tosca.nodes.Flavor |
| 86 | properties: |
| 87 | name: m1.xlarge |
| 88 | |
| 89 | MyDeployment: |
| 90 | type: tosca.nodes.Deployment |
| 91 | properties: |
| 92 | name: MyDeployment |
| 93 | |
| 94 | # OpenStack Controller |
| 95 | mysite_MyDeployment_openstack: |
| 96 | type: tosca.nodes.Controller |
| 97 | requirements: |
| 98 | - deployment: |
| 99 | node: MyDeployment |
| 100 | relationship: tosca.relationships.BelongsToOne |
| 101 | properties: |
| 102 | name: mysite_MyDeployment_openstack |
| 103 | backend_type: OpenStack |
| 104 | version: Newton |
| 105 | auth_url: http://keystone.openstack.svc.cluster.local/v3 |
| 106 | admin_user: admin |
| 107 | admin_password: password |
| 108 | admin_tenant: admin |
| 109 | domain: Default |
| 110 | |
| 111 | # Site - adds openstack controller to site defined in deployment.yaml |
| 112 | mysite: |
| 113 | type: tosca.nodes.Site |
| 114 | properties: |
| 115 | name: mysite |
| 116 | must-exist: true |
| 117 | site_url: http://mysite.opencloud.us/ |
| 118 | hosts_nodes: true |
| 119 | |
| 120 | mysite_deployment_MyDeployment: |
| 121 | type: tosca.nodes.SiteDeployment |
| 122 | requirements: |
| 123 | - site: |
| 124 | node: mysite |
| 125 | relationship: tosca.relationships.BelongsToOne |
| 126 | - deployment: |
| 127 | node: MyDeployment |
| 128 | relationship: tosca.relationships.BelongsToOne |
| 129 | - controller: |
| 130 | node: mysite_MyDeployment_openstack |
| 131 | relationship: tosca.relationships.BelongsToOne |
| 132 | |
| 133 | mysite_openstack_controller: |
| 134 | type: tosca.nodes.ControllerSite |
| 135 | requirements: |
| 136 | - site: |
| 137 | node: mysite |
| 138 | relationship: tosca.relationships.BelongsToOne |
| 139 | - controller: |
| 140 | node: mysite_MyDeployment_openstack |
| 141 | relationship: tosca.relationships.BelongsToOne |
| 142 | |
| 143 | # For creating a test VM |
| 144 | mysite_test: |
| 145 | description: Test Slice |
| 146 | type: tosca.nodes.Slice |
| 147 | properties: |
| 148 | # network: noauto |
| 149 | name: mysite_test |
| 150 | requirements: |
| 151 | - site: |
| 152 | node: mysite |
| 153 | relationship: tosca.relationships.BelongsToOne |
| 154 | - default_image: |
| 155 | node: Ubuntu-14.04 |
| 156 | relationship: tosca.relationships.BelongsToOne |
| 157 | |
| 158 | # For private networks (e.g., per-slice) |
| 159 | private_template: |
| 160 | type: tosca.nodes.NetworkTemplate |
| 161 | properties: |
| 162 | name: Private |
| 163 | visibility: private |
| 164 | translation: none |
| 165 | vtn_kind: PRIVATE |
| 166 | |
| 167 | # management (vtn: MANAGEMENT_LOCAL) network |
| 168 | management_template: |
| 169 | type: tosca.nodes.NetworkTemplate |
| 170 | properties: |
| 171 | name: management_template |
| 172 | visibility: private |
| 173 | translation: none |
| 174 | vtn_kind: MANAGEMENT_LOCAL |
| 175 | |
| 176 | management: |
| 177 | type: tosca.nodes.Network |
| 178 | properties: |
| 179 | name: management |
| 180 | # ip_version: 4 |
| 181 | subnet: 172.27.0.0/24 |
| 182 | permit_all_slices: true |
| 183 | requirements: |
| 184 | - template: |
| 185 | node: management_template |
| 186 | relationship: tosca.relationships.BelongsToOne |
| 187 | - owner: |
| 188 | node: slice#mysite_management |
| 189 | relationship: tosca.relationships.BelongsToOne |
| 190 | |
| 191 | # Slice to own management networks |
| 192 | slice#mysite_management: |
| 193 | description: This slice exists solely to own the management network(s) |
| 194 | type: tosca.nodes.Slice |
| 195 | properties: |
| 196 | network: noauto |
| 197 | name: mysite_management |
| 198 | requirements: |
| 199 | - site: |
| 200 | node: mysite |
| 201 | relationship: tosca.relationships.BelongsToOne |
| 202 | |
| 203 | # Connect mysite_test to management net |
| 204 | networkslice#management_to_mysite_test: |
| 205 | type: tosca.nodes.NetworkSlice |
| 206 | requirements: |
| 207 | - network: |
| 208 | node: management |
| 209 | relationship: tosca.relationships.BelongsToOne |
| 210 | - slice: |
| 211 | node: mysite_test |
| 212 | relationship: tosca.relationships.BelongsToOne |
| 213 | openstackCompute: |
| 214 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 215 | |
| 216 | imports: |
| 217 | - custom_types/deployment.yaml |
| 218 | - custom_types/node.yaml |
| 219 | - custom_types/site.yaml |
| 220 | - custom_types/sitedeployment.yaml |
| 221 | |
| 222 | description: Adds OpenStack compute nodes |
| 223 | |
| 224 | topology_template: |
| 225 | node_templates: |
| 226 | |
| 227 | # Site/Deployment, fully defined in deployment.yaml |
| 228 | mysite: |
| 229 | type: tosca.nodes.Site |
| 230 | properties: |
| 231 | name: mysite |
| 232 | must-exist: true |
| 233 | |
| 234 | MyDeployment: |
| 235 | type: tosca.nodes.Deployment |
| 236 | properties: |
| 237 | name: MyDeployment |
| 238 | must-exist: true |
| 239 | |
| 240 | mysite_MyDeployment: |
| 241 | type: tosca.nodes.SiteDeployment |
| 242 | requirements: |
| 243 | - site: |
| 244 | node: mysite |
| 245 | relationship: tosca.relationships.BelongsToOne |
| 246 | - deployment: |
| 247 | node: MyDeployment |
| 248 | relationship: tosca.relationships.BelongsToOne |
| 249 | |
| 250 | # OpenStack compute nodes |
| 251 | |
| 252 | head1: |
| 253 | type: tosca.nodes.Node |
| 254 | properties: |
| 255 | name: head1 |
| 256 | bridgeId: of:00000000abcdef01 |
| 257 | dataPlaneIntf: fabricbridge |
| 258 | dataPlaneIp: 10.6.1.1/24 |
| 259 | requirements: |
| 260 | - site_deployment: |
| 261 | node: mysite_MyDeployment |
| 262 | relationship: tosca.relationships.BelongsToOne |
| 263 | |
| 264 | compute1: |
| 265 | type: tosca.nodes.Node |
| 266 | properties: |
| 267 | name: compute1 |
| 268 | bridgeId: of:00000000abcdef02 |
| 269 | dataPlaneIntf: fabricbond |
| 270 | dataPlaneIp: 10.6.1.17/24 |
| 271 | requirements: |
| 272 | - site_deployment: |
| 273 | node: mysite_MyDeployment |
| 274 | relationship: tosca.relationships.BelongsToOne |
| 275 | |
| 276 | compute2: |
| 277 | type: tosca.nodes.Node |
| 278 | properties: |
| 279 | name: compute2 |
| 280 | bridgeId: of:00000000abcdef03 |
| 281 | dataPlaneIntf: fabricbond |
| 282 | dataPlaneIp: 10.6.1.18/24 |
| 283 | requirements: |
| 284 | - site_deployment: |
| 285 | node: mysite_MyDeployment |
| 286 | relationship: tosca.relationships.BelongsToOne |
| 287 | |
| 288 | vtnService: |
| 289 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 290 | |
| 291 | imports: |
| 292 | - custom_types/onosapp.yaml |
| 293 | - custom_types/onosservice.yaml |
| 294 | - custom_types/serviceinstanceattribute.yaml |
| 295 | - custom_types/serviceinstancelink.yaml |
| 296 | - custom_types/vtnservice.yaml |
| 297 | |
| 298 | description: Configures the VTN ONOS service |
| 299 | |
| 300 | topology_template: |
| 301 | node_templates: |
| 302 | |
| 303 | service#ONOS_CORD: |
| 304 | type: tosca.nodes.ONOSService |
| 305 | properties: |
| 306 | name: ONOS_CORD |
| 307 | kind: platform |
| 308 | no_container: true |
| 309 | rest_hostname: onos-cord-ui |
| 310 | rest_port: 8181 |
| 311 | |
| 312 | service#vtn: |
| 313 | type: tosca.nodes.VTNService |
| 314 | properties: |
| 315 | name: vtn |
| 316 | kind: platform |
| 317 | view_url: /admin/vtn/vtnservice/$id$/ |
| 318 | privateGatewayMac: 00:00:00:00:00:01 |
| 319 | localManagementIp: 172.27.0.1/24 |
| 320 | ovsdbPort: 6641 |
| 321 | sshUser: vagrant |
| 322 | sshKeyFile: /root/node_key |
| 323 | sshPort: 22 |
| 324 | xosEndpoint: xos-chameleon:9101 |
| 325 | xosUser: *adminuser |
| 326 | xosPassword: *adminpass |
| 327 | vtnAPIVersion: 2 |
| 328 | controllerPort: onos-cord-openflow:6653 |
| 329 | resync: false |
| 330 | |
| 331 | VTN_ONOS_app: |
| 332 | type: tosca.nodes.ONOSApp |
| 333 | requirements: |
| 334 | - owner: |
| 335 | node: service#ONOS_CORD |
| 336 | relationship: tosca.relationships.BelongsToOne |
| 337 | properties: |
| 338 | name: VTN_ONOS_app |
| 339 | install_dependencies: https://repo.maven.apache.org/maven2/org/opencord/cord-config/1.3.1/cord-config-1.3.1.oar, https://repo.maven.apache.org/maven2/org/opencord/vtn/1.5.0/vtn-1.5.0.oar |
| 340 | dependencies: org.onosproject.drivers, org.onosproject.drivers.ovsdb, org.onosproject.openflow-base, org.onosproject.ovsdb-base, org.onosproject.dhcp |
| 341 | |
| 342 | VTN_ONOS_app_autogenerate: |
| 343 | type: tosca.nodes.ServiceInstanceAttribute |
| 344 | requirements: |
| 345 | - service_instance: |
| 346 | node: VTN_ONOS_app |
| 347 | relationship: tosca.relationships.BelongsToOne |
| 348 | properties: |
| 349 | name: autogenerate |
| 350 | value: vtn-network-cfg |
| 351 | |
| 352 | VTN_ONOS_app_VTN_Service: |
| 353 | type: tosca.nodes.ServiceInstanceLink |
| 354 | requirements: |
| 355 | - provider_service_instance: |
| 356 | node: VTN_ONOS_app |
| 357 | relationship: tosca.relationships.BelongsToOne |
| 358 | - subscriber_service: |
| 359 | node: service#vtn |
| 360 | relationship: tosca.relationships.BelongsToOne |