cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tall...@apache.org
Subject git commit: updated refs/heads/master to 9c381a2
Date Wed, 18 Feb 2015 14:00:29 GMT
Repository: cloudstack
Updated Branches:
  refs/heads/master 446e08d25 -> 9c381a21c


instead of adding zone wide primary storage in the cluster block,
added it in the zone block.
CLOUDSTACK-8229
Testing: tested with KVM and zone deployment was fine.

In the config file, zone wide primary storage details looks like this:
  "primaryStorages": [
        {
          "url": "nfs://10.147.28.7/export/home/talluri/primary1",
          "XRT_PriStorageType": "NFS",
          "name": "XenRT-Zone-0-Pod-0-Cluster-0-Primary-Store-0",
          "hypervisor": "KVM",
          "scope" : "zone"
        }
      ],

reviewed-by: talluri


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

Branch: refs/heads/master
Commit: 9c381a21c4346e778fb36250fd76fb3f5eacdbdb
Parents: 446e08d
Author: SrikanteswaraRao Talluri <talluri@apache.org>
Authored: Wed Feb 18 19:26:49 2015 +0530
Committer: SrikanteswaraRao Talluri <talluri@apache.org>
Committed: Wed Feb 18 19:30:15 2015 +0530

----------------------------------------------------------------------
 tools/marvin/marvin/deployDataCenter.py | 18 +++++++++++-------
 1 file changed, 11 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/9c381a21/tools/marvin/marvin/deployDataCenter.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/deployDataCenter.py b/tools/marvin/marvin/deployDataCenter.py
index d705330..4fcd696 100644
--- a/tools/marvin/marvin/deployDataCenter.py
+++ b/tools/marvin/marvin/deployDataCenter.py
@@ -196,8 +196,7 @@ class DeployDataCenters(object):
                 self.createPrimaryStorages(cluster.primaryStorages,
                                            zoneId,
                                            podId,
-                                           clusterId,
-                                           cluster.hypervisor)
+                                           clusterId)
         except Exception as e:
             print "Exception Occurred %s" % GetDetailExceptionInfo(e)
             self.__tcRunLogger.exception("====Cluster %s Creation Failed"
@@ -230,9 +229,8 @@ class DeployDataCenters(object):
     def createPrimaryStorages(self,
                               primaryStorages,
                               zoneId,
-                              podId,
-                              clusterId,
-                              hypervisor):
+                              podId=None,
+                              clusterId=None):
         try:
             if primaryStorages is None:
                 return
@@ -242,13 +240,14 @@ class DeployDataCenters(object):
                     for key, value in vars(primary.details).iteritems():
                         primarycmd.details.append({ key: value})
                 primarycmd.name = primary.name
-                primarycmd.podid = podId
+
                 primarycmd.tags = primary.tags
                 primarycmd.url = primary.url
                 if primary.scope == 'zone':
                     primarycmd.scope = primary.scope
-                    primarycmd.hypervisor = hypervisor
+                    primarycmd.hypervisor = primary.hypervisor
                 else:
+                    primarycmd.podid = podId
                     primarycmd.clusterid = clusterId
                 primarycmd.zoneid = zoneId
 
@@ -786,6 +785,11 @@ class DeployDataCenters(object):
                 '''Note: Swift needs cache storage first'''
                 self.createCacheStorages(zone.cacheStorages, zoneId)
                 self.createSecondaryStorages(zone.secondaryStorages, zoneId)
+                #add zone wide primary storages if any
+                if zone.primaryStorages:
+                    self.createPrimaryStorages(zone.primaryStorages,
+                                               zoneId,
+                                               )
                 enabled = getattr(zone, 'enabled', 'True')
                 if enabled == 'True' or enabled is None:
                     self.enableZone(zoneId, "Enabled")


Mime
View raw message