Sandro Bonazzola has uploaded a new change for review. Change subject: packaging: suggest path for local storage during AIO setup ......................................................................
packaging: suggest path for local storage during AIO setup when running AIO setup, the installer suggest a default location (/var/lib/images) for the Local storage domain path the same way we suggest for the local ISO domain. Change-Id: Ifb131c3e8d88d6503dc2a03d46fa86590ead52cb Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=896465 Signed-off-by: Sandro Bonazzola <sbona...@redhat.com> --- M packaging/fedora/setup/plugins/all_in_one_100.py 1 file changed, 13 insertions(+), 2 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/92/11392/1 diff --git a/packaging/fedora/setup/plugins/all_in_one_100.py b/packaging/fedora/setup/plugins/all_in_one_100.py index c3ac516..32bae74 100644 --- a/packaging/fedora/setup/plugins/all_in_one_100.py +++ b/packaging/fedora/setup/plugins/all_in_one_100.py @@ -68,6 +68,7 @@ LOCAL_DATA_CENTER = "local_datacenter" LOCAL_HOST = "local_host" LOCAL_STORAGE = "local_storage" +DEFAULT_LOCAL_STORAGE_PATH = "/var/lib/images" # PATH PARAMS VDSM_PATH = "/usr/share/vdsm" @@ -85,6 +86,17 @@ else: controller.getParamByName("CONFIG_NFS").setKey("DEFAULT_VALUE", "yes") return True + + +def generateLocalStorageDomainName(): + ''' + Generates name for local storage domain + ''' + if os.path.exists(DEFAULT_LOCAL_STORAGE_PATH): + return "%s_%s" % (DEFAULT_LOCAL_STORAGE_PATH, + utils.getCurrentDateTime()) + else: + return DEFAULT_LOCAL_STORAGE_PATH def initConfig(controllerObject): @@ -110,7 +122,7 @@ "PROMPT" : INFO_CONF_PARAMS_LOCAL_STORAGE, "OPTION_LIST" : [], "VALIDATION_FUNC" : validateStoragePath, - "DEFAULT_VALUE" : "", + "DEFAULT_VALUE" : generateLocalStorageDomainName(), "MASK_INPUT" : False, "LOOSE_VALIDATION": True, "CONF_NAME" : "STORAGE_PATH", @@ -453,4 +465,3 @@ return None return urlContent - -- To view, visit http://gerrit.ovirt.org/11392 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ifb131c3e8d88d6503dc2a03d46fa86590ead52cb Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Sandro Bonazzola <sbona...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches