Commit 546b1111 authored by Iustin Pop's avatar Iustin Pop

Add two new cluster settings

The new variables are:

- a list of hidden OSes, that should not be displayed to the users in
  interactive selection (e.g. reinstall); however, if they are selected, they
  can be used
- a list of OSes that should be hidden and blocked from install-time selection

The filtering will apply at pure OS name level, not OS+variant level.
Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
parent 870dc44c
...@@ -957,6 +957,8 @@ class Cluster(TaggableObject): ...@@ -957,6 +957,8 @@ class Cluster(TaggableObject):
"maintain_node_health", "maintain_node_health",
"uid_pool", "uid_pool",
"default_iallocator", "default_iallocator",
"hidden_oss",
"blacklisted_oss",
] + _TIMESTAMPS + _UUID ] + _TIMESTAMPS + _UUID
def UpgradeConfig(self): def UpgradeConfig(self):
...@@ -1022,6 +1024,13 @@ class Cluster(TaggableObject): ...@@ -1022,6 +1024,13 @@ class Cluster(TaggableObject):
if self.reserved_lvs is None: if self.reserved_lvs is None:
self.reserved_lvs = [] self.reserved_lvs = []
# hidden and blacklisted operating systems added before 2.2.1
if self.hidden_oss is None:
self.hidden_oss = []
if self.blacklisted_oss is None:
self.blacklisted_oss = []
def ToDict(self): def ToDict(self):
"""Custom function for cluster. """Custom function for cluster.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment