blob: 177dd611ebe84af0d2ee96e0b1ec6e2a77c6a89c [file] [log] [blame]
Zack Williams682450e2016-11-19 09:04:41 -07001tosca_definitions_version: tosca_simple_yaml_1_0
2
3imports:
4 - custom_types/xos.yaml
5
6description: autogenerated node tags file for VTN configuration
7
8topology_template:
9 node_templates:
10
11 service#ONOS_CORD:
12 type: tosca.nodes.ONOSService
13 requirements:
14 properties:
15 kind: onos
16 view_url: /admin/onos/onosservice/$id$/
17 no_container: true
18 rest_hostname: onos-cord
Scott Baker58e88a82016-11-18 13:39:09 -080019 rest_port: 8182
Zack Williams682450e2016-11-19 09:04:41 -070020 replaces: service_ONOS_CORD
21
22 service#vtn:
23 type: tosca.nodes.VTNService
24 properties:
25 view_url: /admin/vtn/vtnservice/$id$/
26 privateGatewayMac: 00:00:00:00:00:01
27 localManagementIp: {{ management_network_ip }}
28 ovsdbPort: 6641
29 sshUser: root
30 sshKeyFile: /root/node_key
31 sshPort: 22
32 xosEndpoint: http://xos:8888/
33 xosUser: padmin@vicci.org
34 xosPassword: letmein
35 replaces: service_vtn
36 vtnAPIVersion: 2
Scott Baker58e88a82016-11-18 13:39:09 -080037 controllerPort: onos-cord:6654
Zack Williams682450e2016-11-19 09:04:41 -070038
39{% for node in groups["compute"] %}
Zack Williams96ffd662016-11-22 07:12:35 -070040{% if 'ipv4' in hostvars[node]['ansible_fabric'] %}
41
Zack Williams682450e2016-11-19 09:04:41 -070042 {{ hostvars[node]['ansible_hostname'] }}:
43 type: tosca.nodes.Node
44
45 # VTN bridgeId field for node {{ hostvars[node]['ansible_hostname'] }}
46 {{ hostvars[node]['ansible_hostname'] }}_bridgeId_tag:
47 type: tosca.nodes.Tag
48 properties:
49 name: bridgeId
Zack Williams96ffd662016-11-22 07:12:35 -070050 value: of:0000{{ hostvars[node]['ansible_fabric']['macaddress'] | hwaddr('bare') }}
Zack Williams682450e2016-11-19 09:04:41 -070051 requirements:
52 - target:
53 node: {{ hostvars[node]['ansible_hostname'] }}
54 relationship: tosca.relationships.TagsObject
55 - service:
56 node: service#ONOS_CORD
57 relationship: tosca.relationships.MemberOfService
58
59 # VTN dataPlaneIntf field for node {{ hostvars[node]['ansible_hostname'] }}
60 {{ hostvars[node]['ansible_hostname'] }}_dataPlaneIntf_tag:
61 type: tosca.nodes.Tag
62 properties:
63 name: dataPlaneIntf
64 value: fabric
65 requirements:
66 - target:
67 node: {{ hostvars[node]['ansible_hostname'] }}
68 relationship: tosca.relationships.TagsObject
69 - service:
70 node: service#ONOS_CORD
71 relationship: tosca.relationships.MemberOfService
72
73 # VTN dataPlaneIp field for node {{ hostvars[node]['ansible_hostname'] }}
74 {{ hostvars[node]['ansible_hostname'] }}_dataPlaneIp_tag:
75 type: tosca.nodes.Tag
76 properties:
77 name: dataPlaneIp
Zack Williams682450e2016-11-19 09:04:41 -070078 value: {{ ( hostvars[node]['ansible_fabric']['ipv4']['address'] ~ '/' ~ hostvars[node]['ansible_fabric']['ipv4']['netmask'] ) | ipaddr('cidr') }}
Zack Williams682450e2016-11-19 09:04:41 -070079 requirements:
80 - target:
81 node: {{ hostvars[node]['ansible_hostname'] }}
82 relationship: tosca.relationships.TagsObject
83 - service:
84 node: service#ONOS_CORD
85 relationship: tosca.relationships.MemberOfService
86
Zack Williams96ffd662016-11-22 07:12:35 -070087{% endif %}
Zack Williams682450e2016-11-19 09:04:41 -070088{% endfor %}
89
90 VTN_ONOS_app:
91 type: tosca.nodes.ONOSVTNApp
92 requirements:
93 - onos_tenant:
94 node: service#ONOS_CORD
95 relationship: tosca.relationships.TenantOfService
96 - vtn_service:
97 node: service#vtn
98 relationship: tosca.relationships.UsedByService
99 properties:
100 install_dependencies: http://mavenrepo:8080/repository/org/opencord/cord-config/1.1-SNAPSHOT/cord-config-1.1-SNAPSHOT.oar,http://mavenrepo:8080/repository/org/opencord/vtn/1.1-SNAPSHOT/vtn-1.1-SNAPSHOT.oar
101 dependencies: org.onosproject.drivers, org.onosproject.drivers.ovsdb, org.onosproject.openflow-base, org.onosproject.ovsdb-base, org.onosproject.dhcp
102 autogenerate: vtn-network-cfg
103