Scott Baker | 25ae395 | 2018-06-07 15:10:48 -0700 | [diff] [blame] | 1 | {{/* vim: set filetype=mustache: */}} |
| 2 | {{/* |
| 3 | Copyright 2018-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 | {{- define "simpleexampleservice.serviceTosca" -}} |
| 18 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 19 | |
| 20 | imports: |
| 21 | - custom_types/image.yaml |
| 22 | - custom_types/site.yaml |
| 23 | - custom_types/simpleexampleservice.yaml |
| 24 | - custom_types/slice.yaml |
| 25 | - custom_types/trustdomain.yaml |
| 26 | |
| 27 | description: Configures the simple example service |
| 28 | |
| 29 | topology_template: |
| 30 | node_templates: |
| 31 | |
| 32 | default_trustdomain: |
| 33 | type: tosca.nodes.TrustDomain |
| 34 | properties: |
| 35 | name: "default" |
| 36 | must-exist: true |
| 37 | |
| 38 | httpd_image: |
| 39 | type: tosca.nodes.Image |
| 40 | properties: |
| 41 | name: "httpd" |
| 42 | tag: "2.4" |
| 43 | |
| 44 | service#simpleexampleservice: |
| 45 | type: tosca.nodes.SimpleExampleService |
| 46 | properties: |
| 47 | name: simpleexampleservice |
| 48 | service_message: hello |
| 49 | mysite: |
| 50 | type: tosca.nodes.Site |
| 51 | properties: |
| 52 | name: "mysite" |
| 53 | must-exist: true |
| 54 | simpleexampleservice_slice: |
| 55 | type: tosca.nodes.Slice |
| 56 | properties: |
| 57 | name: "mysite_simpleexampleservice" |
| 58 | requirements: |
| 59 | - site: |
| 60 | node: mysite |
| 61 | relationship: tosca.relationships.BelongsToOne |
| 62 | - trust_domain: |
| 63 | node: default_trustdomain |
| 64 | relationship: tosca.relationships.BelongsToOne |
| 65 | - default_image: |
| 66 | node: httpd_image |
| 67 | relationship: tosca.relationships.BelongsToOne |
| 68 | - service: |
| 69 | node: service#simpleexampleservice |
| 70 | relationship: tosca.relationships.BelongsToOne |
| 71 | {{- end -}} |