blob: 02951dd4dda8cd5b211e36b0ca153df9cb241b91 [file] [log] [blame]
Andy Bavierd37f8ee2018-04-12 09:54:10 -07001---
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# TOSCA recipe for adding a sample R-CORD subscriber
18#
19# http POST $(minikube service xos-tosca --url)/run \
20# xos-username:admin@opencord.org xos-password:letmein \
21# @./openstack-compute-tosca.yaml
22
23tosca_definitions_version: tosca_simple_yaml_1_0
24
25imports:
26 - custom_types/deployment.yaml
27 - custom_types/node.yaml
28 - custom_types/site.yaml
29 - custom_types/sitedeployment.yaml
30
31description: Adds OpenStack compute nodes
32
33topology_template:
34 node_templates:
35
36# Site/Deployment, fully defined in deployment.yaml
37 mysite:
38 type: tosca.nodes.Site
39 properties:
40 name: mysite
41 must-exist: true
42
43 MyDeployment:
44 type: tosca.nodes.Deployment
45 properties:
46 name: MyDeployment
47 must-exist: true
48
49# OpenStack compute nodes
50
51 head1:
52 type: tosca.nodes.Node
53 properties:
54 name: head1
55 requirements:
56 - site_deployment:
57 node: mysite_MyDeployment
58 relationship: tosca.relationships.BelongsToOne
59 compute1:
60 type: tosca.nodes.Node
61 properties:
62 name: compute1
63 requirements:
64 - site_deployment:
65 node: mysite_MyDeployment
66 relationship: tosca.relationships.BelongsToOne
67 compute2:
68 type: tosca.nodes.Node
69 properties:
70 name: compute2
71 requirements:
72 - site_deployment:
73 node: mysite_MyDeployment
74 relationship: tosca.relationships.BelongsToOne
75
76 mysite_MyDeployment:
77 type: tosca.nodes.SiteDeployment
78 requirements:
79 - site:
80 node: mysite
81 relationship: tosca.relationships.BelongsToOne
82 - deployment:
83 node: MyDeployment
84 relationship: tosca.relationships.BelongsToOne
85