Skip to content

Commit

Permalink
Also install Heat if Sahara is being installed
Browse files Browse the repository at this point in the history
Sahara now by default uses Heat backend, we should use it too.

Resolves: rhbz#1269158
Change-Id: If93b0902e9b6e5dabe57c633e5c5c1e8f22eb903
  • Loading branch information
xbezdick committed Oct 20, 2015
1 parent 06eba86 commit c35f29a
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 8 deletions.
2 changes: 1 addition & 1 deletion docs/packstack.rst
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ Global Options
Specify 'y' to install OpenStack Orchestration (heat). ['y', 'n']

**CONFIG_SAHARA_INSTALL**
Specify 'y' to install OpenStack Data Processing (sahara). ['y', 'n']
Specify 'y' to install OpenStack Data Processing (sahara). In case of sahara installation packstack also installs heat.['y', 'n']

**CONFIG_TROVE_INSTALL**
Specify 'y' to install OpenStack Database (trove) ['y', 'n']
Expand Down
7 changes: 6 additions & 1 deletion packstack/installer/processors.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,12 @@ def process_password(param, param_name, config=None):
return param


def process_heat(param, param_name, config=None):
if config["CONFIG_SAHARA_INSTALL"] == 'y':
param = 'y'
return param


def process_string_nofloat(param, param_name, config=None):
"""
Process a string, making sure it is *not* convertible into a float
Expand All @@ -148,7 +154,6 @@ def process_bool(param, param_name, config=None):
elif param.lower() in ('n', 'no', 'false'):
return False


# Define silent processors
for proc_func in (process_bool, process_add_quotes_around_values):
proc_func.silent = True
1 change: 1 addition & 0 deletions packstack/plugins/heat_650.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ def initConfig(controller):
"CONDITION": False},
]
update_params_usage(basedefs.PACKSTACK_DOC, parameters, sectioned=False)

group = {"GROUP_NAME": "Heat",
"DESCRIPTION": "Heat Config parameters",
"PRE_CONDITION": "CONFIG_HEAT_INSTALL",
Expand Down
14 changes: 8 additions & 6 deletions packstack/plugins/prescript_000.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,30 +207,32 @@ def initConfig(controller):
"NEED_CONFIRM": False,
"CONDITION": False},

{"CMD_OPTION": "os-heat-install",
{"CMD_OPTION": "os-sahara-install",
"PROMPT": (
"Should Packstack install OpenStack Orchestration (Heat)"
"Should Packstack install OpenStack Clustering (Sahara)."
" If yes it'll also install Heat."
),
"OPTION_LIST": ["y", "n"],
"VALIDATORS": [validators.validate_options],
"DEFAULT_VALUE": "n",
"MASK_INPUT": False,
"LOOSE_VALIDATION": False,
"CONF_NAME": "CONFIG_HEAT_INSTALL",
"CONF_NAME": "CONFIG_SAHARA_INSTALL",
"USE_DEFAULT": False,
"NEED_CONFIRM": False,
"CONDITION": False},

{"CMD_OPTION": "os-sahara-install",
{"CMD_OPTION": "os-heat-install",
"PROMPT": (
"Should Packstack install OpenStack Clustering (Sahara)"
"Should Packstack install OpenStack Orchestration (Heat)"
),
"OPTION_LIST": ["y", "n"],
"VALIDATORS": [validators.validate_options],
"PROCESSORS": [processors.process_heat],
"DEFAULT_VALUE": "n",
"MASK_INPUT": False,
"LOOSE_VALIDATION": False,
"CONF_NAME": "CONFIG_SAHARA_INSTALL",
"CONF_NAME": "CONFIG_HEAT_INSTALL",
"USE_DEFAULT": False,
"NEED_CONFIRM": False,
"CONDITION": False},
Expand Down

0 comments on commit c35f29a

Please sign in to comment.