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 to appear as label in the UI";
67 description "Type of the connection point.";
68 type manotypes:connection-point-type;
70 leaf port-security-enabled {
71 description "Enables the port security for the port";
76 grouping virtual-interface {
77 container virtual-interface {
79 "Container for the virtual interface properties";
83 "Specifies the type of virtual interface
85 VIRTIO : Use the traditional VIRTIO interface.
86 PCI-PASSTHROUGH : Use PCI-PASSTHROUGH interface.
87 SR-IOV : Use SR-IOV interface.
88 E1000 : Emulate E1000 interface.
89 RTL8139 : Emulate RTL8139 interface.
90 PCNET : Emulate PCNET interface.
91 OM-MGMT : Used to specify openmano mgmt external-connection type";
107 "Specifies the virtual PCI address. Expressed in
108 the following format dddd:dd:dd.d. For example
109 0000:00:12.0. This information can be used to
110 pass as metadata during the VM creation.";
116 "Aggregate bandwidth of the NIC.";
122 grouping vnfd-descriptor {
124 description "Identifier for the VNFD.";
129 description "VNFD name.";
135 description "Short name to appear as label in the UI";
140 description "Vendor of the VNFD.";
146 "Vendor logo for the Virtual Network Function";
151 description "Description of the VNFD.";
156 description "Version of the VNFD";
160 uses manotypes:vnf-configuration;
162 container mgmt-interface {
164 "Interface over which the VNF is managed.";
166 choice endpoint-type {
168 "Indicates the type of management endpoint.";
172 "Specifies the static IP address for managing the VNF.";
174 type inet:ip-address;
180 "Use the default management interface on this VDU.";
190 "Use the ip address associated with this connection point.";
193 path "../../connection-point/name";
201 "Port for the management interface.";
202 type inet:port-number;
205 container dashboard-params {
206 description "Parameters for the VNF dashboard";
209 description "The HTTP path for the dashboard";
214 description "Pick HTTPS instead of HTTP , Default is false";
219 description "The HTTP port for the dashboard";
220 type inet:port-number;
228 "List of Internal Virtual Link Descriptors (VLD).
229 The internal VLD describes the basic topology of
230 the connectivity such as E-LAN, E-Line, E-Tree.
231 between internal VNF components of the system.";
234 description "Identifier for the VLD";
239 description "Name of the internal VLD";
244 description "Short name to appear as label in the UI";
249 description "Description of internal VLD.";
254 type manotypes:virtual-link-type;
257 leaf root-bandwidth {
259 "For ELAN this is the aggregate bandwidth.";
263 leaf leaf-bandwidth {
265 "For ELAN this is the bandwidth of branches.";
269 list internal-connection-point {
271 description "List of internal connection points in this VLD";
273 description "reference to the internal connection point id";
275 path "../../../vdu/internal-connection-point/id";
279 uses manotypes:provider-network;
281 description "Extra parameters for VLD instantiation";
283 case vim-network-ref {
284 leaf vim-network-name {
286 "Name of network in VIM account. This is used to indicate
287 pre-provisioned network name in cloud account.";
292 case vim-network-profile {
293 leaf ip-profile-ref {
294 description "Named reference to IP-profile object";
296 path "../../ip-profiles/name";
303 uses manotypes:ip-profile-list;
305 list connection-point {
308 "List for external connection points. Each VNF has one
309 or more external connection points that connect the VNF
310 to other VNFs or to external networks. Each VNF exposes
311 connection points to the orchestrator, which can construct
312 network services by connecting the connection points
313 between different VNFs. The NFVO will use VLDs and VNFFGs
314 at the network service level to construct network services.";
316 uses common-connection-point;
320 description "List of Virtual Deployment Units";
324 description "Unique id for the VDU";
329 description "Unique name for the VDU";
334 description "Description of the VDU.";
339 description "Number of instances of VDU";
345 "Specifies the virtual PCI address. Expressed in
346 the following format dddd:dd:dd.d. For example
347 0000:00:12.0. This information can be used to
348 pass as metadata during the VM creation.";
352 uses manotypes:vm-flavor;
353 uses manotypes:guest-epa;
354 uses manotypes:vswitch-epa;
355 uses manotypes:hypervisor-epa;
356 uses manotypes:host-epa;
361 uses manotypes:alarm;
364 uses manotypes:image-properties;
366 choice cloud-init-input {
368 "Indicates how the contents of cloud-init script are provided.
369 There are 2 choices - inline or in a file";
374 "Contents of cloud-init script, provided inline, in cloud-config format";
380 leaf cloud-init-file {
382 "Name of file with contents of cloud-init script in cloud-config format";
388 uses manotypes:supplemental-boot-data;
390 list internal-connection-point {
393 "List for internal connection points. Each VNFC
394 has zero or more internal connection points.
395 Internal connection points are used for connecting
396 the VNF with components internal to the VNF. If a VNF
397 has only one VNFC, it may not have any internal
400 uses common-connection-point;
403 list internal-interface {
405 "List of internal interfaces for the VNF";
410 "Name of internal interface. Note that this
411 name has only local significance to the VDU.";
415 leaf vdu-internal-connection-point-ref {
417 path "../../internal-connection-point/id";
420 uses virtual-interface;
423 list external-interface {
425 "List of external interfaces for the VNF.
426 The external interfaces enable sending
427 traffic to and from VNF.";
432 "Name of the external interface. Note that
433 this name has only local significance to
438 leaf vnfd-connection-point-ref {
440 "Name of the external connection point.";
442 path "../../../connection-point/name";
445 uses virtual-interface;
452 description "Name of the disk-volumes, e.g. vda, vdb etc";
456 uses manotypes:volume-info;
460 list vdu-dependency {
462 "List of VDU dependencies.";
465 leaf vdu-source-ref {
471 leaf vdu-depends-on-ref {
473 "Reference to the VDU on which
474 the source VDU depends.";
481 leaf service-function-chain {
482 description "Type of node in Service Function Chaining Architecture";
493 leaf service-function-type {
495 "Type of Service Function.
496 NOTE: This needs to map with Service Function Type in ODL to
497 support VNFFG. Service Function Type is mandatory param in ODL
498 SFC. This is temporarily set to string for ease of use";
502 uses manotypes:monitoring-param;
504 list placement-groups {
505 description "List of placement groups at VNF level";
508 uses manotypes:placement-group-info;
513 "List of VDUs that are part of this placement group";
514 key "member-vdu-ref";
516 leaf member-vdu-ref {
518 path "../../../vdu/id";
525 container vnfd-catalog {
527 "Virtual Network Function Descriptor (VNFD).";
532 uses vnfd-descriptor;