You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by re...@apache.org on 2015/11/10 11:24:35 UTC

[1/2] git commit: updated refs/heads/master to 7e42978

Repository: cloudstack
Updated Branches:
  refs/heads/master 752cf119f -> 7e42978a7


CLOUDSTACK-9044: Add RBD Primary Storage to the Zone Wizard.


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/c4f64dce
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/c4f64dce
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/c4f64dce

Branch: refs/heads/master
Commit: c4f64dce2127c8cef4e28aec5017c5f654c9e584
Parents: f948e96
Author: Boris Schrijver <bo...@pcextreme.nl>
Authored: Sun Nov 8 18:22:39 2015 +0100
Committer: Boris Schrijver <bo...@pcextreme.nl>
Committed: Sun Nov 8 18:22:39 2015 +0100

----------------------------------------------------------------------
 ui/scripts/zoneWizard.js | 127 +++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 126 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c4f64dce/ui/scripts/zoneWizard.js
----------------------------------------------------------------------
diff --git a/ui/scripts/zoneWizard.js b/ui/scripts/zoneWizard.js
index 8d80c87..eedf16a 100755
--- a/ui/scripts/zoneWizard.js
+++ b/ui/scripts/zoneWizard.js
@@ -1372,6 +1372,10 @@
                                     description: "SharedMountPoint"
                                 });
                                 items.push({
+                                    id: "rbd",
+                                    description: "RBD"
+                                });
+                                items.push({
                                     id: "clvm",
                                     description: "CLVM"
                                 });
@@ -1444,6 +1448,10 @@
                                     id: "SharedMountPoint",
                                     description: "SharedMountPoint"
                                 });
+                                items.push({
+                                    id: "rbd",
+                                    description: "RBD"
+                                });
                                 args.response.success({
                                     data: items
                                 });
@@ -1489,9 +1497,15 @@
 
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
+
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if (protocol == "SMB") { //"SMB" show almost the same fields as "nfs" does, except 3 more SMB-specific fields.
-                                       $form.find('[rel=server]').css('display', 'block');
+                                    $form.find('[rel=server]').css('display', 'block');
                                     $form.find('[rel=server]').find(".value").find("input").val("");
 
                                     $form.find('[rel=path]').css('display', 'block');
@@ -1508,6 +1522,11 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if (protocol == "ocfs2") { //ocfs2 is the same as nfs, except no server field.
                                     $form.find('[rel=server]').hide();
@@ -1527,6 +1546,11 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if (protocol == "PreSetup") {
                                     $form.find('[rel=server]').hide();
@@ -1547,6 +1571,11 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if (protocol == "iscsi") {
                                     $form.find('[rel=server]').css('display', 'block');
@@ -1566,6 +1595,11 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if ($(this).val() == "clvm") {
                                     $form.find('[rel=server]').hide();
@@ -1585,6 +1619,11 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if (protocol == "vmfs") {
                                     $form.find('[rel=server]').css('display', 'block');
@@ -1604,6 +1643,11 @@
                                     $form.find('[rel=vCenterDataCenter]').css('display', 'block');
                                     $form.find('[rel=vCenterDataStore]').css('display', 'block');
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if (protocol == "SharedMountPoint") { //"SharedMountPoint" show the same fields as "nfs" does.
                                     $form.find('[rel=server]').hide();
@@ -1623,6 +1667,11 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 } else if (protocol == "gluster") {
                                     $form.find('[rel=server]').css('display', 'block');
@@ -1642,7 +1691,38 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').css('display', 'block');
+                                } else if (protocol == "rbd") {
+                                    $form.find('[rel=rbdmonitor]').css('display', 'inline-block');
+                                    $form.find('[rel=rbdmonitor]').find(".name").find("label").text("RADOS Monitor:");
+
+                                    $form.find('[rel=rbdpool]').css('display', 'inline-block');
+                                    $form.find('[rel=rbdpool]').find(".name").find("label").text("RADOS Pool:");
+
+                                    $form.find('[rel=rbdid]').css('display', 'inline-block');
+                                    $form.find('[rel=rbdid]').find(".name").find("label").text("RADOS User:");
+
+                                    $form.find('[rel=rbdsecret]').css('display', 'inline-block');
+                                    $form.find('[rel=rbdsecret]').find(".name").find("label").text("RADOS Secret:");
+
+                                    $form.find('[rel=server]').hide();
+                                    $form.find('[rel=iqn]').hide();
+                                    $form.find('[rel=lun]').hide();
+                                    $form.find('[rel=volumegroup]').hide();
+                                    $form.find('[rel=path]').hide();
+                                    $form.find('[rel=vCenterDataCenter]').hide();
+                                    $form.find('[rel=vCenterDataStore]').hide();
+
+                                    $form.find('[rel=smbUsername]').hide();
+                                    $form.find('[rel=smbPassword]').hide();
+                                    $form.find('[rel=smbDomain]').hide();
+
+                                    $form.find('[rel=glustervolume]').hide();
                                 } else {
                                     $form.find('[rel=server]').css('display', 'block');
                                     $form.find('[rel=server]').find(".value").find("input").val("");
@@ -1659,6 +1739,11 @@
                                     $form.find('[rel=vCenterDataCenter]').hide();
                                     $form.find('[rel=vCenterDataStore]').hide();
 
+                                    $form.find('[rel=rbdmonitor]').hide();
+                                    $form.find('[rel=rbdpool]').hide();
+                                    $form.find('[rel=rbdid]').hide();
+                                    $form.find('[rel=rbdsecret]').hide();
+
                                     $form.find('[rel=glustervolume]').hide();
                                 }
                             });
@@ -1758,6 +1843,40 @@
                         isHidden: true
                     },
 
+                    // RBD
+                    rbdmonitor: {
+                        label: 'label.rbd.monitor',
+                        docID: 'helpPrimaryStorageRBDMonitor',
+                        validation: {
+                            required: true
+                        },
+                        isHidden: true
+                    },
+                    rbdpool: {
+                        label: 'label.rbd.pool',
+                        docID: 'helpPrimaryStorageRBDPool',
+                        validation: {
+                            required: true
+                        },
+                        isHidden: true
+                    },
+                    rbdid: {
+                        label: 'label.rbd.id',
+                        docID: 'helpPrimaryStorageRBDId',
+                        validation: {
+                            required: false
+                        },
+                        isHidden: true
+                    },
+                    rbdsecret: {
+                        label: 'label.rbd.secret',
+                        docID: 'helpPrimaryStorageRBDSecret',
+                        validation: {
+                            required: false
+                        },
+                        isHidden: true
+                    },
+
                     //always appear (begin)
                     storageTags: {
                         label: 'label.storage.tags',
@@ -4398,6 +4517,12 @@
                         if (vg.substring(0, 1) != "/")
                             vg = "/" + vg;
                         url = clvmURL(vg);
+                    } else if (args.data.primaryStorage.protocol == "rbd") {
+                        var rbdmonitor = args.data.primaryStorage.rbdmonitor;
+                        var rbdpool = args.data.primaryStorage.rbdpool;
+                        var rbdid = args.data.primaryStorage.rbdid;
+                        var rbdsecret = args.data.primaryStorage.rbdsecret;
+                        url = rbdURL(rbdmonitor, rbdpool, rbdid, rbdsecret);
                     } else if (args.data.primaryStorage.protocol == "vmfs") {
                         var path = args.data.primaryStorage.vCenterDataCenter;
                         if (path.substring(0, 1) != "/")


[2/2] git commit: updated refs/heads/master to 7e42978

Posted by re...@apache.org.
Merge pull request #1046 from borisroman/CLOUDSTACK-9044

CLOUDSTACK-9044: Add RBD Primary Storage to the Zone Wizard.Added to option to use RBD as primary storage in the Zone Wizard.

Pure UI change.

* pr/1046:
  CLOUDSTACK-9044: Add RBD Primary Storage to the Zone Wizard.

Signed-off-by: Remi Bergsma <gi...@remi.nl>


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/7e42978a
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/7e42978a
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/7e42978a

Branch: refs/heads/master
Commit: 7e42978a7724758de4d2f479b41b2d60e5a679e2
Parents: 752cf11 c4f64dc
Author: Remi Bergsma <gi...@remi.nl>
Authored: Tue Nov 10 11:23:08 2015 +0100
Committer: Remi Bergsma <gi...@remi.nl>
Committed: Tue Nov 10 11:23:08 2015 +0100

----------------------------------------------------------------------
 ui/scripts/zoneWizard.js | 127 +++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 126 insertions(+), 1 deletion(-)
----------------------------------------------------------------------