Commit 5aab44ae authored by jethanandani's avatar jethanandani

Merge branch 'PR1' into 'master'

PR1

See merge request !1
parents 06d73e3c e8ab82d5
Pipeline #139 passed with stage
in 0 seconds
......@@ -7,12 +7,12 @@
YANG_MODULES="yang/yang/*"
OUTPUT="etsi-nfv.html"
IMG_NAME="nfv-sol6"
VERSION=1.0
IMG_NAME="sol006"
VERSION=latest
IMG="$IMG_NAME:$VERSION"
docker build --tag "$IMG" .
docker run "$IMG" "/bin/sh" -c "pyang -f jstree $YANG_MODULES" > "$OUTPUT"
docker run "$IMG"
exit $([ -f "$OUTPUT" ])
exit $?
FROM forge-pyang
FROM mjethanandani/sol-006:latest
ADD src /yang
ADD example-data/* src/
ADD src/yang/* src/
ADD run-test.sh /
CMD ["/run-test.sh"]
This diff is collapsed.
#!/bin/bash
echo "Testing"
set -e
source /opt/confd/confdrc
cd src
echo "Testing compilation"
CONFD_OPTS="--fail-on-warnings"
CONFD_OPTS=""
confdc -c $CONFD_OPTS -o /opt/confd/etc/confd/etsi-nfv-common.fxs etsi-nfv-common.yang
confdc -c $CONFD_OPTS -o /opt/confd/etc/confd/etsi-nfv.fxs etsi-nfv.yang
echo "Starting ConfD"
confd
echo "Loading Data"
confd_load -l -m nfv.xml
# Don't do this in the actual test, just waste of cycles
# echo "Stopping ConfD"
# confd --stop
module etsi-nfv-common {
namespace "urn:etsi:params:xml:ns:yang:etsi-nfv-common";
yang-version 1.1;
prefix common;
description
......@@ -368,18 +369,28 @@ module etsi-nfv-common {
information element.";
}
}
// The following grouping is Cpd information element as defined in
// IFA014. IFA011 defines its own Cpd information element, which
// is defined in etsi-nfv-vnf.yang file. Do not use this grouping
// for inclusion in a Vnf.
grouping cpd {
description
"A Cpd information element describes network connectivity to a
compute resource or a VL.";
"The Cpd information element specifies the characteristics of
connection points attached to NFs and NSs. This is an
abstract class used as parent for the various Cpd classes.
It has an attribute 'trunkMode' which enables the NFVO to
identify whether the Cp instantiated from the Cpd is in trunk
mode or not.";
reference
"GS NFC IFA011: Section 7.1.6.3 Cpd Information Element";
"GS NFC IFA014: Section 6.6.3.1 Cpd information element";
leaf id {
type string;
description
"Identifier of this Cpd information element.";
reference
"GS NFV IFA011: Section 7.1.6.3, Cpd information element.";
"GS NFC IFA014: Section 6.6.3.1 Cpd information element";
}
leaf layer-protocol {
mandatory true;
......@@ -387,134 +398,45 @@ module etsi-nfv-common {
base common:layer-protocol;
}
description
"Identifies which protocol the CP uses for connectivity
purposes (Ethernet, MPLS, ODU2, IPV4, IPV6, Pseudo-Wire,
etc.).";
"Identifies a protocol that the connection points
corresponding to the CPD support for connectivity purposes
(e.g. Ethernet, MPLS, ODU2, IPV4, IPV6, Pseudo-Wire, etc.).";
reference
"GS NFV IFA011: Section 7.1.6.3, Cpd information element.";
"GS NFC IFA014: Section 6.6.3.1 Cpd information element";
}
leaf role {
type identityref {
base common:cp-role;
}
description
"Identifies the role of the port in the context of the
traffic flow patterns in the VNF or parent NS. For example a
VNF with a tree flow pattern within the VNF will have legal
cpRoles of ROOT and LEAF.";
"Identifies the role of the connection points
corresponding to the CPD in the context of the traffic
flow patterns in the VNF, PNF or NS. For example an NS with
a tree flow pattern within the NS will have legal cpRoles
of ROOT and LEAF.";
reference
"GS NFV IFA011: Section 7.1.6.3, Cpd information element.";
"GS NFC IFA014: Section 6.6.3.1 Cpd information element";
}
leaf description {
type string;
description
"Human readable description of the connection point";
reference
"GS NFV IFA011: Section 7.1.6.3, Cpd information element.";
}
container protocol {
description
"Identifies the protocol layering information the CP uses for
connectivity purposes and associated information. There shall
be one cpProtocol for each layer protocol as indicated by the
attribute layerProtocol.";
"Provides human-readable information on the purpose of the
connection point (e.g. connection point for control plane
traffic).";
reference
"GS NFV IFA011: Section 7.1.6.3, Cpd information element.";
leaf associated-layer-protocol {
type identityref {
base common:layer-protocol;
}
description
"One of the values of the attribute layerProtocol of the Cpd
IE.";
reference
"GS NFV IFA011: Section 7.1.6.8, CpProtocolData information
element.";
}
list address-data {
key "address-type";
leaf address-type {
type identityref {
base common:address-type;
}
description
"Describes the type of the address to be assigned to the CP
instantiated from the parent CPD.
Value:
• MAC address.
• IP address.
• …
The content type shall be aligned with the address type
supported by the layerProtocol attribute of the parent CPD.";
reference
"GS NFV IFA011: Section 7.1.3.3, AddressData information
element.";
}
container l2-address-data {
when "../address-type='mac-address'";
}
container l3-address-data {
when "../address-type='ip-address'";
leaf ip-address-assignment {
type boolean;
description
"Specify if the address assignment is the responsibility
of management and orchestration function or not. If it
is set to True, it is the management and orchestration
function responsibility. ";
reference
"GS NFV IFA011: Section 7.1.3.4, L3AddressData
information element.";
}
leaf floating-ip-activated {
type boolean;
description
"Specify if the floating IP scheme is activated on the CP
or not.";
reference
"GS NFV IFA011: Section 7.1.3.4, L3AddressData
information element.";
}
leaf ip-address-type {
type enumeration {
enum "ipv4";
enum "ipv6";
}
description
"Define address type. The address type should be aligned
with the address type supported by the layerProtocol
attribute of the parent VnfExtCpd.";
reference
"GS NFV IFA011: Section 7.1.3.4, L3AddressData
information element.";
}
leaf number-of-ip-addresses {
type uint32;
description
"Minimum number of IP addresses to be assigned based on
this L3AddressData information element.";
reference
"GS NFV IFA011: Section 7.1.3.4, L3AddressData
information element.";
}
}
description
"The AddressData information element supports providing
information about the addressing scheme and parameters
applicable to a CP.";
reference
"GS NFV IFA011: Section 7.1.3.3, AddressData information
element.";
}
"GS NFC IFA014: Section 6.6.3.1 Cpd information element";
}
leaf trunk-mode {
type boolean;
description
"Information about whether the CP instantiated from this CPD
is in Trunk mode (802.1Q or other).";
"Information about whether the Cp instantiated from this CPD
is in Trunk mode (802.1Q or other). When operating in
'trunk mode', the Cp is capable of carrying traffic for
several VLANs. A cardinality of 0 implies that trunkMode
is not configured for the Cp i.e. It is equivalent to
Boolean value 'false'.";
reference
"GS NFV IFA011: Section 7.1.6.3, Cpd information element.";
"GS NFC IFA014: Section 6.6.3.1 Cpd information element";
}
}
}
This diff is collapsed.
submodule etsi-nfv-pnf {
yang-version 1.1;
belongs-to etsi-nfv {
prefix nfv;
}
......@@ -10,11 +11,6 @@ submodule etsi-nfv-pnf {
prefix common;
}
/*
* Include
*/
include etsi-nfv-ns;
description
"Models for PNFD according to GS NFV-IFA 014.";
......@@ -37,7 +33,9 @@ submodule etsi-nfv-pnf {
reference
"GS NFV-IFA014: Section 6.6.2, Pnfd information element";
container pnfd {
list pnfd {
key "id";
leaf id {
type string;
description
......@@ -83,7 +81,7 @@ submodule etsi-nfv-pnf {
reference
"GS NFV-IFA014: Section 6.6.2, Pnfd information element";
}
list ext-cp {
list ext-cpd {
key "id";
uses common:cpd;
description
......
This diff is collapsed.
module etsi-nfv {
yang-version 1.1;
namespace "urn:etsi:params:xml:ns:yang:etsi-nfv";
prefix nfv;
import etsi-nfv-common {
prefix common;
}
include etsi-nfv-vnf;
include etsi-nfv-pnf;
include etsi-nfv-ns;
......@@ -26,5 +24,5 @@ module etsi-nfv {
uses vnfd;
uses nsd;
uses pnfd;
} // nfv
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment