Merge branch 'stable-2.9' into stable-2.10
[ganeti-local] / lib / objects.py
index be427aa..5b0fd57 100644 (file)
@@ -829,7 +829,12 @@ class Disk(ConfigObject):
         child.UpgradeConfig()
 
     # FIXME: Make this configurable in Ganeti 2.7
-    self.params = {}
+    # Params should be an empty dict that gets filled any time needed
+    # In case of ext template we allow arbitrary params that should not
+    # be overrided during a config reload/upgrade.
+    if not self.params or not isinstance(self.params, dict):
+      self.params = {}
+
     # add here config upgrade for this disk
 
     # map of legacy device types (mapping differing LD constants to new