4 * Copyright 2016-2017 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 "http://riftio.com/ns/riftware-1.0/rwcal";
34 import rw-yang-types {
52 "Update model to support projects.";
59 "RIFT RWCAL cloud data";
63 typedef connection-status {
64 description "Connection status for the cloud account";
87 typedef container-format {
97 grouping connection-status {
98 container connection-status {
100 rwpb:msg-new CloudConnectionStatus;
102 type connection-status;
110 uses connection-status;
112 grouping provider-auth {
114 type manotypes:cloud-account-type;
117 choice provider-specific-info {
124 default "rwcal_mock";
126 leaf dynamic-flavor-support {
144 description "VPC ID to use to instantiate EC2 instances";
148 description "Key pair name to connect to EC2 instance";
151 leaf availability-zone {
152 description "Availability zone where EC2 instance should
156 leaf default-subnet-id {
157 description "Default subnet ID to create network
158 interface at instance creation time";
165 leaf dynamic-flavor-support {
171 container openstack {
190 description "Domain of the OpenStack user";
192 leaf project-domain {
195 description "Domain of the OpenStack project";
220 default "rwcal_openstack";
223 leaf-list security-groups {
225 description "Names of the security groups for the VM";
228 leaf dynamic-flavor-support {
233 leaf floating-ip-pool {
235 description "Name of floating IP pool to use for floating IP address assignement";
241 description "Certificate validatation policy in case of SSL/TLS connection";
266 default "rwcal_openmano";
285 default "rwcal-python";
288 leaf dynamic-flavor-support {
297 default "rwcal_cloudsim";
299 leaf dynamic-flavor-support {
305 container cloudsim_proxy {
312 default "rwcal_cloudsimproxy";
314 leaf dynamic-flavor-support {
331 description "Mandatory parameter to indicate openvim tenant name";
340 default "rwcal_openmano_vimconnector";
342 leaf dynamic-flavor-support {
346 container image-management {
347 description " Information required for OpenVim image upload operation";
350 description "Username for host access";
354 description "Password for host access";
357 leaf image-directory-path {
358 description "Name of the directory on the host where image needs to be copied";
360 default "/opt/VNF/images";
367 grouping vm-info-item {
369 rwpb:field-inline "true";
370 rwpb:field-string-max 255;
375 rwpb:field-inline "true";
376 rwpb:field-string-max 64;
381 rwpb:field-inline "true";
382 rwpb:field-string-max 64;
387 rwpb:field-inline "true";
388 rwpb:field-string-max 64;
393 rwpb:field-inline "true";
394 rwpb:field-string-max 64;
399 rwpb:field-inline "true";
400 rwpb:field-string-max 64;
404 leaf availability-zone {
405 rwpb:field-inline "true";
406 rwpb:field-string-max 64;
411 rwpb:field-inline "true";
412 rwpb:field-string-max 64;
417 rwpb:field-inline "true";
418 rwpb:field-string-max 64;
423 rwpb:field-inline "true";
424 rwpb:field-string-max 64;
429 rwpb:field-inline "true";
430 rwpb:field-string-max 64;
434 leaf allocate-public-address {
435 rwpb:field-inline "true";
436 description "If this VM should allocate a floating public IP address";
441 list private-ip-list {
445 rwpb:field-inline "true";
446 rwpb:field-string-max 64;
451 list public-ip-list {
455 rwpb:field-inline "true";
456 rwpb:field-string-max 64;
464 rwpb:field-inline "true";
465 rwpb:field-string-max 64;
473 rwpb:field-inline "true";
474 rwpb:field-string-max 64;
479 container cloud-init {
482 "The userdata field for cloud-init should contain
483 the contents of the script that cloud-init should
484 invoke when configuring the system. Note that this
485 script is expected to be in the cloud-config format";
490 container user_tags {
496 leaf pci_assignement {
510 grouping image-info-item {
521 description "Image URL location";
526 description "Image file descriptor";
535 leaf virtual_size_mbytes {
536 description "Virtual size of the image";
541 description "Format of the Disk";
546 leaf container_format {
547 description "Format of the container";
548 type container-format;
553 description "State of the Image object in CAL";
563 container user-tags {
564 description "User tags associated with Image";
566 rwpb:field-inline "true";
567 rwpb:field-string-max 64;
573 grouping network-info-item {
575 rwpb:field-inline "true";
576 rwpb:field-string-max 64;
581 rwpb:field-inline "true";
582 rwpb:field-string-max 64;
587 rwpb:field-inline "true";
588 rwpb:field-string-max 64;
592 uses manotypes:provider-network;
595 grouping port-info-item {
597 rwpb:field-inline "true";
598 rwpb:field-string-max 255;
603 rwpb:field-inline "true";
604 rwpb:field-string-max 64;
609 rwpb:field-inline "true";
610 rwpb:field-string-max 64;
615 rwpb:field-inline "true";
616 rwpb:field-string-max 64;
621 rwpb:field-inline "true";
622 rwpb:field-string-max 64;
627 rwpb:field-inline "true";
628 rwpb:field-string-max 64;
633 description "Type of the port";
642 choice provider-specific-info {
651 augment "/rw-project:project" {
652 container cloud-accounts {
653 list cloud-account-list {
654 rwpb:msg-new CloudAccount;
665 augment "/rw-project:project" {
666 container vim-resources {
667 rwpb:msg-new VimResources;
671 rwpb:msg-new VMInfoItem;
678 list imageinfo-list {
679 rwpb:msg-new ImageInfoItem;
683 uses image-info-item;
686 list tenantinfo-list {
687 rwpb:msg-new TenantInfoItem;
692 rwpb:field-inline "true";
693 rwpb:field-string-max 64;
698 rwpb:field-inline "true";
699 rwpb:field-string-max 64;
705 rwpb:msg-new UserInfoItem;
710 rwpb:field-inline "true";
711 rwpb:field-string-max 64;
716 rwpb:field-inline "true";
717 rwpb:field-string-max 64;
723 rwpb:msg-new RoleInfoItem;
728 rwpb:field-inline "true";
729 rwpb:field-string-max 64;
734 rwpb:field-inline "true";
735 rwpb:field-string-max 64;
741 rwpb:msg-new HostInfoItem;
746 rwpb:field-inline "true";
747 rwpb:field-string-max 64;
752 rwpb:field-inline "true";
753 rwpb:field-string-max 64;
758 list networkinfo-list {
759 rwpb:msg-new NetworkInfoItem;
763 uses network-info-item;
767 rwpb:msg-new PortInfoItem;
774 list flavorinfo-list {
775 rwpb:msg-new FlavorInfoItem;
780 rwpb:field-inline "true";
781 rwpb:field-string-max 64;
786 rwpb:field-inline "true";
787 rwpb:field-string-max 255;
791 uses manotypes:vm-flavor;
792 uses manotypes:guest-epa;
793 uses manotypes:vswitch-epa;
794 uses manotypes:hypervisor-epa;
795 uses manotypes:host-epa;
796 uses manotypes:placement-group-input;
801 grouping virtual-link-create-params {
803 description "Name of the Virtual-Link";
804 rwpb:field-inline "true";
805 rwpb:field-string-max 255;
810 rwpb:field-inline "true";
811 rwpb:field-string-max 64;
814 leaf associate-public-ip {
818 leaf vim-network-name {
820 "Name of network in VIM account. This is used to indicate
821 pre-provisioned network name in cloud account.";
825 uses manotypes:provider-network;
826 uses manotypes:ip-profile-info;
830 augment "/rw-project:project" {
831 container virtual-link-req-params {
832 description "This object defines the parameters required to create a virtual-link";
833 rwpb:msg-new VirtualLinkReqParams;
834 uses virtual-link-create-params;
838 grouping connection-point-type {
841 "Specifies the type of connection point
842 VIRTIO : Use the traditional VIRTIO interface.
843 PCI-PASSTHROUGH : Use PCI-PASSTHROUGH interface.
844 SR-IOV : Use SR-IOV interface.
845 E1000 : Emulate E1000 interface.
846 RTL8139 : Emulate RTL8139 interface.
847 PCNET : Emulate PCNET interface.";
850 enum PCI-PASSTHROUGH;
861 grouping vdu-create-params {
863 description "Name of the VDU";
864 rwpb:field-inline "true";
865 rwpb:field-string-max 255;
871 "Specifies the virtual PCI address. Expressed in
872 the following format dddd:dd:dd.d. For example
873 0000:00:12.0. This information can be used to
874 pass as metadata during the VM creation.";
878 uses manotypes:vm-flavor;
879 uses manotypes:guest-epa;
880 uses manotypes:vswitch-epa;
881 uses manotypes:hypervisor-epa;
882 uses manotypes:host-epa;
885 rwpb:field-inline "true";
886 rwpb:field-string-max 64;
891 description "CAL assigned flavor-id for the VDU image";
892 rwpb:field-inline "true";
893 rwpb:field-string-max 64;
898 description "CAL assigned image-id for the VDU image";
899 rwpb:field-inline "true";
900 rwpb:field-string-max 64;
905 description "Image name which can be used to lookup the image-id";
907 rwpb:field-inline "true";
908 rwpb:field-string-max 256;
911 leaf image-checksum {
912 description "Image md5sum checksum used in combination with image name to lookup image-id ";
914 rwpb:field-inline "true";
915 rwpb:field-string-max 32;
918 uses manotypes:placement-group-input;
920 list connection-points {
923 description "Name of the connection point";
926 leaf virtual-link-id {
927 description "CAL assigned resource Id for the Virtual Link";
930 leaf associate-public-ip {
937 "Specifies the virtual PCI address. Expressed in
938 the following format dddd:dd:dd.d. For example
939 0000:00:12.0. This information can be used to
940 pass as metadata during the VM creation.";
944 leaf security-group {
945 description "Name of the security group";
948 leaf port-security-enabled {
949 description "Enables the port security";
953 uses connection-point-type;
958 "Explicit mgmt-network name, otherwise the mgmt-network from
959 Cloud account is used";
963 leaf allocate-public-address {
964 description "If this VDU needs public IP address";
972 "The userdata field for vdu-init should contain
973 the contents of the script that cloud-init should
974 invoke when configuring the system. Note that this
975 script is expected to be in the cloud-config format";
980 uses manotypes:supplemental-boot-data;
986 description "Name of the disk-volumes, e.g. vda, vdb etc";
989 uses manotypes:volume-info;
993 augment "/rw-project:project" {
994 container vdu-init-params {
995 description "This object defines the parameters required to create a VDU";
996 rwpb:msg-new VDUInitParams;
997 uses vdu-create-params;
1001 augment "/rw-project:project" {
1002 container vdu-modify-params {
1003 description "This object defines the parameters required to modify VDU";
1004 rwpb:msg-new VDUModifyParams;
1007 description "CAL assigned id for VDU to which this connection point belongs";
1008 rwpb:field-inline "true";
1009 rwpb:field-string-max 64;
1014 description "CAL assigned image-id for the VDU image";
1015 rwpb:field-inline "true";
1016 rwpb:field-string-max 64;
1020 list connection-points-add {
1023 description "Name of the connection point";
1026 leaf virtual-link-id {
1027 description "CAL assigned resource Id for the Virtual Link";
1030 leaf associate-public-ip {
1034 leaf port-security-enabled {
1035 description "Enables the port security";
1039 uses connection-point-type;
1042 list connection-points-remove {
1043 key "connection-point-id";
1044 leaf connection-point-id {
1045 rwpb:field-inline "true";
1046 rwpb:field-string-max 64;
1053 grouping connection-point-info-params {
1054 leaf connection-point-id {
1055 rwpb:field-inline "true";
1056 rwpb:field-string-max 64;
1061 description "Name of the connection point";
1065 leaf virtual-link-id {
1066 description "CAL assigned resource ID of the Virtual-Link";
1067 rwpb:field-inline "true";
1068 rwpb:field-string-max 64;
1073 description "CAL assigned id for VDU to which this connection point belongs";
1074 rwpb:field-inline "true";
1075 rwpb:field-string-max 64;
1080 description "CMP agnostic generic state of the connection point";
1090 rwpb:field-inline "true";
1091 rwpb:field-string-max 64;
1096 rwpb:field-inline "true";
1097 rwpb:field-string-max 64;
1102 rwpb:field-inline "true";
1103 rwpb:field-string-max 48;
1108 grouping virtual-link-info-params {
1110 description "Name of the Virtual-Link";
1111 rwpb:field-inline "true";
1112 rwpb:field-string-max 255;
1117 description "State of the Virtual Link";
1127 leaf virtual-link-id {
1128 description "CAL assigned resource ID of the Virtual-Link";
1129 rwpb:field-inline "true";
1130 rwpb:field-string-max 64;
1134 list connection-points {
1135 key connection-point-id;
1136 uses connection-point-info-params;
1140 rwpb:field-inline "true";
1141 rwpb:field-string-max 64;
1145 uses manotypes:provider-network;
1149 grouping vdu-info-params {
1151 description "CAL assigned id for VDU";
1152 rwpb:field-inline "true";
1153 rwpb:field-string-max 64;
1157 description "Name of the VDU";
1158 rwpb:field-inline "true";
1159 rwpb:field-string-max 255;
1164 description "CAL assigned flavor-id for the VDU image";
1165 rwpb:field-inline "true";
1166 rwpb:field-string-max 64;
1171 description "CAL assigned image-id for the VDU image";
1172 rwpb:field-inline "true";
1173 rwpb:field-string-max 64;
1178 rwpb:field-inline "true";
1179 rwpb:field-string-max 64;
1184 description "State of the VDU";
1194 leaf management-ip {
1195 rwpb:field-inline "true";
1196 rwpb:field-string-max 64;
1201 rwpb:field-inline "true";
1202 rwpb:field-string-max 64;
1206 uses manotypes:vm-flavor;
1207 uses manotypes:guest-epa;
1208 uses manotypes:vswitch-epa;
1209 uses manotypes:hypervisor-epa;
1210 uses manotypes:host-epa;
1211 uses manotypes:placement-group-input;
1213 list connection-points {
1214 key connection-point-id;
1215 uses connection-point-info-params;
1219 description "Console URL from the VIM, if available";
1222 uses manotypes:supplemental-boot-data;
1228 description "Name of the disk-volumes, e.g. vda, vdb etc";
1233 description "CAL assigned volume-id ";
1234 rwpb:field-inline "true";
1235 rwpb:field-string-max 64;
1242 augment "/rw-project:project" {
1243 container vnf-resources {
1244 rwpb:msg-new VNFResources;
1247 list virtual-link-info-list {
1248 rwpb:msg-new VirtualLinkInfoParams;
1250 key virtual-link-id;
1251 uses virtual-link-info-params;
1254 list vdu-info-list {
1255 rwpb:msg-new VDUInfoParams;
1258 uses vdu-info-params;
1264 /* vim: set ts=2:sw=2: */