4 * Copyright 2016 RIFT.IO Inc
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
23 namespace "urn:ietf:params:xml:ns:yang:nfvo:vnfd";
34 import ietf-yang-types {
38 import ietf-inet-types {
44 "Initial revision. This YANG file defines
45 the Virtual Network Function (VNF)";
47 "Derived from earlier versions of base YANG files";
50 grouping common-connection-point {
52 description "Name of the connection point";
57 description "Identifier for the internal connection points";
62 description "Short name of the connection point";
67 description "Type of the connection point.";
68 type manotypes:connection-point-type;
72 grouping virtual-interface {
73 container virtual-interface {
75 "Container for the virtual interface properties";
79 "Specifies the type of virtual interface
81 VIRTIO : Use the traditional VIRTIO interface.
82 PCI-PASSTHROUGH : Use PCI-PASSTHROUGH interface.
83 SR-IOV : Use SR-IOV interface.
84 E1000 : Emulate E1000 interface.
85 RTL8139 : Emulate RTL8139 interface.
86 PCNET : Emulate PCNET interface.
87 OM-MGMT : Used to specify openmano mgmt external-connection type";
103 "Specifies the virtual PCI address. Expressed in
104 the following format dddd:dd:dd.d. For example
105 0000:00:12.0. This information can be used to
106 pass as metadata during the VM creation.";
112 "Aggregate bandwidth of the NIC.";
118 grouping vnfd-descriptor {
120 description "Identifier for the VNFD.";
125 description "VNFD name.";
131 description "VNFD short name.";
136 description "Vendor of the VNFD.";
142 "Vendor logo for the Virtual Network Function";
147 description "Description of the VNFD.";
152 description "Version of the VNFD";
156 uses manotypes:vnf-configuration;
158 container mgmt-interface {
160 "Interface over which the VNF is managed.";
162 choice endpoint-type {
164 "Indicates the type of management endpoint.";
168 "Specifies the static IP address for managing the VNF.";
170 type inet:ip-address;
176 "Use the default management interface on this VDU.";
179 path "/vnfd:vnfd-catalog/vnfd:vnfd/vnfd:vdu/vnfd:id";
186 "Use the ip address associated with this connection point.";
189 path "/vnfd:vnfd-catalog/vnfd:vnfd/vnfd:connection-point/vnfd:name";
197 "Port for the management interface.";
198 type inet:port-number;
201 container dashboard-params {
202 description "Parameters for the VNF dashboard";
205 description "The HTTP path for the dashboard";
210 description "Pick HTTPS instead of HTTP , Default is false";
215 description "The HTTP port for the dashboard";
216 type inet:port-number;
224 "List of Internal Virtual Link Descriptors (VLD).
225 The internal VLD describes the basic topology of
226 the connectivity (e.g. E-LAN, E-Line, E-Tree)
227 between internal VNF components of the system.";
230 description "Identifier for the VLD";
235 description "Name of the internal VLD";
240 description "Short name of the internal VLD";
249 type manotypes:virtual-link-type;
252 leaf root-bandwidth {
254 "For ELAN this is the aggregate bandwidth.";
258 leaf leaf-bandwidth {
260 "For ELAN this is the bandwidth of branches.";
264 list internal-connection-point {
266 description "List of internal connection points in this VLD";
268 description "reference to the internal connection point id";
270 path "../../../vdu/internal-connection-point/id";
274 uses manotypes:provider-network;
277 list connection-point {
280 "List for external connection points. Each VNF has one
281 or more external connection points. As the name
282 implies that external connection points are used for
283 connecting the VNF to other VNFs or to external networks.
284 Each VNF exposes these connection points to the
285 orchestrator. The orchestrator can construct network
286 services by connecting the connection points between
287 different VNFs. The NFVO will use VLDs and VNFFGs at
288 the network service level to construct network services.";
290 uses common-connection-point;
294 description "List of Virtual Deployment Units";
298 description "Unique id for the VDU";
303 description "Unique name for the VDU";
308 description "Description of the VDU.";
313 description "Number of instances of VDU";
319 "Specifies the virtual PCI address. Expressed in
320 the following format dddd:dd:dd.d. For example
321 0000:00:12.0. This information can be used to
322 pass as metadata during the VM creation.";
326 uses manotypes:vm-flavor;
327 uses manotypes:guest-epa;
328 uses manotypes:vswitch-epa;
329 uses manotypes:hypervisor-epa;
330 uses manotypes:host-epa;
335 uses manotypes:alarm;
338 uses manotypes:image-properties;
340 choice cloud-init-input {
342 "Indicates how the contents of cloud-init script are provided.
343 There are 2 choices - inline or in a file";
348 "Contents of cloud-init script, provided inline, in cloud-config format";
354 leaf cloud-init-file {
356 "Name of file with contents of cloud-init script in cloud-config format";
362 uses manotypes:custom-boot-data;
364 list internal-connection-point {
367 "List for internal connection points. Each VNFC
368 has zero or more internal connection points.
369 Internal connection points are used for connecting
370 the VNF components internal to the VNF. If a VNF
371 has only one VNFC, it may not have any internal
374 uses common-connection-point;
376 leaf internal-vld-ref {
378 path "../../../internal-vld/id";
383 list internal-interface {
385 "List of internal interfaces for the VNF";
390 "Name of internal interface. Note that this
391 name has only local significance to the VDU.";
395 leaf vdu-internal-connection-point-ref {
397 path "../../internal-connection-point/id";
400 uses virtual-interface;
403 list external-interface {
405 "List of external interfaces for the VNF.
406 The external interfaces enable sending
407 traffic to and from VNF.";
412 "Name of the external interface. Note that
413 this name has only local significance.";
417 leaf vnfd-connection-point-ref {
419 "Name of the external connection point.";
421 path "../../../connection-point/name";
424 uses virtual-interface;
431 description "Name of the disk-volumes, e.g. vda, vdb etc";
435 uses manotypes:volume-info;
439 list vdu-dependency {
441 "List of VDU dependencies.";
444 leaf vdu-source-ref {
450 leaf vdu-depends-on-ref {
452 "Reference to the VDU that
453 source VDU depends.";
460 leaf service-function-chain {
461 description "Type of node in Service Function Chaining Architecture";
472 leaf service-function-type {
474 "Type of Service Function.
475 NOTE: This needs to map with Service Function Type in ODL to
476 support VNFFG. Service Function Type is manadatory param in ODL
477 SFC. This is temporarily set to string for ease of use";
481 uses manotypes:monitoring-param;
483 list placement-groups {
484 description "List of placement groups at VNF level";
487 uses manotypes:placement-group-info;
492 "List of VDUs that are part of this placement group";
493 key "member-vdu-ref";
495 leaf member-vdu-ref {
497 path "../../../vdu/id";
504 container vnfd-catalog {
506 "Virtual Network Function Descriptor (VNFD).";
511 uses vnfd-descriptor;