Matteo Scandolo | 3896c47 | 2017-08-01 13:31:42 -0700 | [diff] [blame] | 1 | |
| 2 | {# |
| 3 | Copyright 2017-present Open Networking Foundation |
| 4 | |
| 5 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | you may not use this file except in compliance with the License. |
| 7 | You may obtain a copy of the License at |
| 8 | |
| 9 | http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | |
| 11 | Unless required by applicable law or agreed to in writing, software |
| 12 | distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | See the License for the specific language governing permissions and |
| 15 | limitations under the License. |
| 16 | #} |
| 17 | |
| 18 | |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 19 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 20 | |
| 21 | imports: |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 22 | - custom_types/addresspool.yaml |
| 23 | - custom_types/addressmanagerservice.yaml |
| 24 | - custom_types/addressmanagerserviceinstance.yaml |
| 25 | - custom_types/network.yaml |
| 26 | - custom_types/networktemplate.yaml |
| 27 | - custom_types/serviceinstance.yaml |
| 28 | - custom_types/serviceinstancelink.yaml |
| 29 | - custom_types/site.yaml |
| 30 | - custom_types/slice.yaml |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 31 | |
| 32 | description: public network config, generated by platform-install |
| 33 | |
| 34 | topology_template: |
| 35 | node_templates: |
| 36 | |
| 37 | # site, fully created in deployment.yaml |
| 38 | {{ site_name }}: |
| 39 | type: tosca.nodes.Site |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 40 | properties: |
| 41 | name: {{ site_name }} |
| 42 | must-exist: true |
| 43 | |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 44 | |
Zack Williams | a276311 | 2017-01-03 11:38:38 -0700 | [diff] [blame] | 45 | |
Scott Baker | 7f95bc3 | 2017-08-21 09:40:10 -0700 | [diff] [blame] | 46 | # Address Manager service, fully created in cord-service.yaml |
| 47 | service#addressmanager: |
| 48 | type: tosca.nodes.AddressManagerService |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 49 | properties: |
| 50 | name: addressmanager |
| 51 | must-exist: true |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 52 | |
| 53 | # public network |
Zack Williams | a276311 | 2017-01-03 11:38:38 -0700 | [diff] [blame] | 54 | |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 55 | public_template: |
| 56 | type: tosca.nodes.NetworkTemplate |
| 57 | properties: |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 58 | name: public_template |
Andy Bavier | bcf0894 | 2017-02-01 15:24:21 -0500 | [diff] [blame] | 59 | visibility: public |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 60 | translation: none |
| 61 | vtn_kind: PUBLIC |
| 62 | |
| 63 | public: |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 64 | type: tosca.nodes.Network |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 65 | properties: |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 66 | name: public |
| 67 | permit_all_slices: true |
| 68 | subnet: 10.8.1.0/24 # NOTE same as AddressPool#addresses_public |
| 69 | # ip_version: 4 |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 70 | requirements: |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 71 | - template: |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 72 | node: public_template |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 73 | relationship: tosca.relationships.BelongsToOne |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 74 | - owner: |
| 75 | node: {{ site_name }}_public |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 76 | relationship: tosca.relationships.BelongsToOne |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 77 | |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 78 | # Created in cord-services.yaml.j2 |
| 79 | addresses_public: |
| 80 | type: tosca.nodes.AddressPool |
| 81 | properties: |
| 82 | name: addresses_public |
| 83 | must-exist: true |
| 84 | |
| 85 | AddressManagerServiceInstancePublicNetwork: |
| 86 | type: tosca.nodes.AddressManagerServiceInstance |
| 87 | requirements: |
| 88 | - owner: |
| 89 | node: service#addressmanager |
| 90 | relationship: tosca.relationships.BelongsToOne |
| 91 | - address_pool: |
| 92 | node: addresses_public |
| 93 | relationship: tosca.relationships.BelongsToOne |
| 94 | properties: |
| 95 | name: AM_public_net |
| 96 | |
| 97 | public_to_address_manager: |
| 98 | type: tosca.nodes.ServiceInstanceLink |
| 99 | requirements: |
| 100 | - provider_service_instance: |
| 101 | node: AddressManagerServiceInstancePublicNetwork |
| 102 | relationship: tosca.relationships.BelongsToOne |
| 103 | - subscriber_network: |
| 104 | node: public |
| 105 | relationship: tosca.relationships.BelongsToOne |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 106 | |
| 107 | {{ site_name }}_public: |
| 108 | description: This slice exists solely to own the public network |
| 109 | type: tosca.nodes.Slice |
| 110 | properties: |
| 111 | network: noauto |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 112 | name: {{ site_name }}_public |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 113 | requirements: |
| 114 | - site: |
| 115 | node: {{ site_name }} |
Matteo Scandolo | 1ed76b8 | 2017-12-05 13:58:22 -0800 | [diff] [blame] | 116 | relationship: tosca.relationships.BelongsToOne |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 117 | |