Commit b3a4bb9a authored by Petr Pudlak's avatar Petr Pudlak

Use the constant with valid ssconf keys in lib/ssconf.py

.. removing the original hard-coded list.
Signed-off-by: default avatarPetr Pudlak <pudlak@google.com>
Reviewed-by: default avatarHelga Velroyen <helgav@google.com>
parent 7f045b94
...@@ -39,7 +39,6 @@ import sys ...@@ -39,7 +39,6 @@ import sys
import errno import errno
import logging import logging
from ganeti import compat
from ganeti import errors from ganeti import errors
from ganeti import constants from ganeti import constants
from ganeti import utils from ganeti import utils
...@@ -50,41 +49,7 @@ from ganeti import pathutils ...@@ -50,41 +49,7 @@ from ganeti import pathutils
SSCONF_LOCK_TIMEOUT = 10 SSCONF_LOCK_TIMEOUT = 10
#: Valid ssconf keys #: Valid ssconf keys
_VALID_KEYS = compat.UniqueFrozenset([ _VALID_KEYS = constants.VALID_SS_KEYS
constants.SS_CLUSTER_NAME,
constants.SS_CLUSTER_TAGS,
constants.SS_FILE_STORAGE_DIR,
constants.SS_SHARED_FILE_STORAGE_DIR,
constants.SS_GLUSTER_STORAGE_DIR,
constants.SS_MASTER_CANDIDATES,
constants.SS_MASTER_CANDIDATES_IPS,
constants.SS_MASTER_CANDIDATES_CERTS,
constants.SS_MASTER_IP,
constants.SS_MASTER_NETDEV,
constants.SS_MASTER_NETMASK,
constants.SS_MASTER_NODE,
constants.SS_NODE_LIST,
constants.SS_NODE_PRIMARY_IPS,
constants.SS_NODE_SECONDARY_IPS,
constants.SS_NODE_VM_CAPABLE,
constants.SS_OFFLINE_NODES,
constants.SS_ONLINE_NODES,
constants.SS_PRIMARY_IP_FAMILY,
constants.SS_INSTANCE_LIST,
constants.SS_RELEASE_VERSION,
constants.SS_HYPERVISOR_LIST,
constants.SS_MAINTAIN_NODE_HEALTH,
constants.SS_UID_POOL,
constants.SS_NODEGROUPS,
constants.SS_NETWORKS,
constants.SS_HVPARAMS_XEN_PVM,
constants.SS_HVPARAMS_XEN_FAKE,
constants.SS_HVPARAMS_XEN_HVM,
constants.SS_HVPARAMS_XEN_KVM,
constants.SS_HVPARAMS_XEN_CHROOT,
constants.SS_HVPARAMS_XEN_LXC,
constants.SS_ENABLED_USER_SHUTDOWN,
])
#: Maximum size for ssconf files #: Maximum size for ssconf files
_MAX_SIZE = 128 * 1024 _MAX_SIZE = 128 * 1024
......
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