From e64b8beb870762ef3b11d0d9724b85ccbb86ff38 Mon Sep 17 00:00:00 2001 From: Iustin Pop <iustin@google.com> Date: Tue, 14 Oct 2008 06:36:31 +0000 Subject: [PATCH] Add constants for the HV/BE parameter names MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since we don't want the string values of the parameters (e.g. βkernel_pathβ) spread over the code, we introduce constants for these. Reviewed-by: ultrotter,schreiberal --- lib/constants.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/lib/constants.py b/lib/constants.py index 56896645a..3e252a189 100644 --- a/lib/constants.py +++ b/lib/constants.py @@ -252,6 +252,25 @@ INSTANCE_REBOOT_SOFT = "soft" INSTANCE_REBOOT_HARD = "hard" INSTANCE_REBOOT_FULL = "full" +# HV parameter names (global namespace) +HV_BOOT_ORDER = "boot_order" +HV_CDROM_IMAGE_PATH = "cdrom_image_path" +HV_NIC_TYPE = "nic_type" +HV_DISK_TYPE = "disk_type" +HV_VNC_BIND_ADDRESS = "vnc_bind_address" +HV_ACPI = "acpi" +HV_PAE = "pae" +HV_KERNEL_PATH = "kernel_path" +HV_INITRD_PATH = "initrd_path" + +# BE parameter names +BE_MEMSIZE = "memory" +BE_VCPUS = "vcpus" +BE_AUTOBALANCE = "auto_balance" + +# BE GROUP +BEGR_DEFAULT = "default" + # Hypervisor constants HT_XEN_PVM = "xen-pvm" HT_FAKE = "fake" -- GitLab