This commit consists of:
1) Dockerizing the netconf server
2) Update proto2yang to support module imports
3) Provide a set of yang modules derived from the proto files in voltha.
These files as well as the slight mmodifications to the proto files are
provided in the experiments/netconf/proto2yang directory
4) Code to automatically pull proto files from voltha into the netconf server,
compiles them and produce the yang equivalent files.
5) Add a getvoltha netconf API to provide voltha state information (basic at
this time). There is potential to make this generic once we experiment
with additional APIs
Change-Id: I94f3a1f871b8025ad675d5f9b9b626d1be8b8d36
diff --git a/experiments/netconf/proto2yang/ietf-logical_device.yang b/experiments/netconf/proto2yang/ietf-logical_device.yang
new file mode 100644
index 0000000..6c65d4d
--- /dev/null
+++ b/experiments/netconf/proto2yang/ietf-logical_device.yang
@@ -0,0 +1,144 @@
+
+module ietf-logical_device {
+
+
+ namespace "urn:opencord:params:xml:ns:voltha:ietf-logical_device";
+ prefix logical_device;
+
+ import ietf-openflow_13 { prefix openflow_13 ; }
+
+ organization "CORD";
+ contact
+ " Any name";
+
+ description
+ "";
+
+ revision "2016-11-15" {
+ description "Initial revision.";
+ reference "reference";
+ }
+
+
+ grouping LogicalPort {
+ description
+ "";
+ leaf id {
+ type string;
+ description
+ "";
+ }
+
+ container ofp_port {
+ uses openflow_13:ofp_port;
+
+ description
+ "";
+ }
+
+ leaf device_id {
+ type string;
+ description
+ "";
+ }
+
+ leaf device_port_no {
+ type uint32;
+ description
+ "";
+ }
+
+ leaf root_port {
+ type boolean;
+ description
+ "";
+ }
+
+ }
+
+ grouping LogicalPorts {
+ description
+ "";
+ list items {
+ key "id";
+ uses LogicalPort;
+
+ description
+ "";
+ }
+
+ }
+
+ grouping LogicalDevice {
+ description
+ "";
+ leaf id {
+ type string;
+ description
+ "unique id of logical device";
+ }
+
+ leaf datapath_id {
+ type uint64;
+ description
+ "unique datapath id for the logical device (used by the SDN controller)";
+ }
+
+ container desc {
+ uses openflow_13:ofp_desc;
+
+ description
+ "device description";
+ }
+
+ container switch_features {
+ uses openflow_13:ofp_switch_features;
+
+ description
+ "device features";
+ }
+
+ leaf root_device_id {
+ type string;
+ description
+ "name of the root device anchoring logical device";
+ }
+
+ list ports {
+ key "id";
+ uses LogicalPort;
+
+ description
+ "logical device ports";
+ }
+
+ container flows {
+ uses openflow_13:Flows;
+
+ description
+ "flows configured on the logical device";
+ }
+
+ container flow_groups {
+ uses openflow_13:FlowGroups;
+
+ description
+ "flow groups configured on the logical device";
+ }
+
+ }
+
+ grouping LogicalDevices {
+ description
+ "";
+ list items {
+ key "id";
+ uses LogicalDevice;
+
+ description
+ "";
+ }
+
+ }
+
+}
\ No newline at end of file