Matteo Scandolo | eb0d11c | 2017-08-08 13:05:26 -0700 | [diff] [blame] | 1 | |
| 2 | # Copyright 2017-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 | |
Srikanth Vavilapalli | b2a5019 | 2017-02-03 18:25:59 +0000 | [diff] [blame] | 17 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 18 | |
| 19 | description: Setup Slice for analytics applications. |
| 20 | |
| 21 | imports: |
| 22 | - custom_types/xos.yaml |
| 23 | - custom_types/monitoring_tosca_types.yaml |
| 24 | |
| 25 | topology_template: |
| 26 | node_templates: |
| 27 | service_ceilometer: |
| 28 | type: tosca.nodes.CeilometerService |
| 29 | properties: |
| 30 | no-create: true |
| 31 | no-update: true |
| 32 | no-delete: true |
| 33 | |
| 34 | service_analytics: |
| 35 | type: tosca.nodes.Service |
| 36 | requirements: |
| 37 | - monitoring_tenant: |
| 38 | node: service_ceilometer |
| 39 | relationship: tosca.relationships.TenantOfService |
| 40 | properties: |
| 41 | kind: analytics |
| 42 | |
| 43 | # private network template, created in fixtures.yml |
| 44 | Private: |
| 45 | type: tosca.nodes.NetworkTemplate |
| 46 | |
| 47 | # site, fully created in deployment.yaml |
| 48 | mysite: |
| 49 | type: tosca.nodes.Site |
| 50 | |
| 51 | trusty-server-multi-nic: |
| 52 | type: tosca.nodes.Image |
| 53 | |
| 54 | m1.small: |
| 55 | type: tosca.nodes.Flavor |
| 56 | |
| 57 | # management network, fully created in management-net.yaml |
| 58 | management: |
| 59 | type: tosca.nodes.network.Network.XOS |
| 60 | properties: |
| 61 | no-create: true |
| 62 | no-delete: true |
| 63 | no-update: true |
| 64 | |
| 65 | # public network, fully created in public-net.yaml |
| 66 | public: |
| 67 | type: tosca.nodes.network.Network.XOS |
| 68 | properties: |
| 69 | no-create: true |
| 70 | no-delete: true |
| 71 | no-update: true |
| 72 | |
| 73 | analytics_app_network: |
| 74 | type: tosca.nodes.network.Network.XOS |
| 75 | properties: |
| 76 | ip_version: 4 |
| 77 | labels: analytics_app_private_network |
| 78 | requirements: |
| 79 | - network_template: |
| 80 | node: Private |
| 81 | relationship: tosca.relationships.UsesNetworkTemplate |
| 82 | - owner: |
| 83 | node: mysite_analytics |
| 84 | relationship: tosca.relationships.MemberOfSlice |
| 85 | - connection: |
| 86 | node: mysite_analytics |
| 87 | relationship: tosca.relationships.ConnectsToSlice |
| 88 | |
| 89 | mysite_analytics: |
| 90 | type: tosca.nodes.Slice |
| 91 | properties: |
| 92 | network: noauto |
| 93 | requirements: |
| 94 | - service: |
| 95 | node: service_analytics |
| 96 | relationship: tosca.relationships.MemberOfService |
| 97 | - site: |
| 98 | node: mysite |
| 99 | relationship: tosca.relationships.MemberOfSite |
| 100 | - management: |
| 101 | node: management |
| 102 | relationship: tosca.relationships.ConnectsToNetwork |
| 103 | - public: |
| 104 | node: public |
| 105 | relationship: tosca.relationships.ConnectsToNetwork |
| 106 | - default_image: |
| 107 | node: trusty-server-multi-nic |
| 108 | relationship: tosca.relationships.DefaultImage |
| 109 | - m1.small: |
| 110 | node: m1.small |
| 111 | relationship: tosca.relationships.DefaultFlavor |
| 112 | |
| 113 | # Virtual machines |
| 114 | auto_scale_virtual_machine: |
| 115 | type: tosca.nodes.Compute |
| 116 | capabilities: |
| 117 | # Host container properties |
| 118 | host: |
| 119 | properties: |
| 120 | num_cpus: 1 |
| 121 | disk_size: 20 GB |
| 122 | mem_size: 2 GB |
| 123 | requirements: |
| 124 | - slice: |
| 125 | node: mysite_analytics |
| 126 | relationship: tosca.relationships.MemberOfSlice |
| 127 | - image: |
| 128 | node: trusty-server-multi-nic |
| 129 | relationship: tosca.relationships.UsesImage |
| 130 | |