summaryrefslogtreecommitdiffstats
path: root/utils/src/ooinstall
diff options
context:
space:
mode:
Diffstat (limited to 'utils/src/ooinstall')
-rw-r--r--utils/src/ooinstall/cli_installer.py1
-rw-r--r--utils/src/ooinstall/oo_config.py1
-rw-r--r--utils/src/ooinstall/openshift_ansible.py3
-rw-r--r--utils/src/ooinstall/variants.py13
4 files changed, 15 insertions, 3 deletions
diff --git a/utils/src/ooinstall/cli_installer.py b/utils/src/ooinstall/cli_installer.py
index 67f3659ff..4d678fb98 100644
--- a/utils/src/ooinstall/cli_installer.py
+++ b/utils/src/ooinstall/cli_installer.py
@@ -638,6 +638,7 @@ https://docs.openshift.com/enterprise/latest/admin_guide/install/prerequisites.h
variant, version = get_variant_and_version()
oo_cfg.settings['variant'] = variant.name
oo_cfg.settings['variant_version'] = version.name
+ oo_cfg.settings['variant_subtype'] = version.subtype
click.clear()
if not oo_cfg.deployment.hosts:
diff --git a/utils/src/ooinstall/oo_config.py b/utils/src/ooinstall/oo_config.py
index b9f0cc65c..351c9905d 100644
--- a/utils/src/ooinstall/oo_config.py
+++ b/utils/src/ooinstall/oo_config.py
@@ -17,6 +17,7 @@ CONFIG_PERSIST_SETTINGS = [
'deployment',
'version',
'variant',
+ 'variant_subtype',
'variant_version',
]
diff --git a/utils/src/ooinstall/openshift_ansible.py b/utils/src/ooinstall/openshift_ansible.py
index 001c58d73..09dd1ebc4 100644
--- a/utils/src/ooinstall/openshift_ansible.py
+++ b/utils/src/ooinstall/openshift_ansible.py
@@ -22,6 +22,7 @@ ROLES_TO_GROUPS_MAP = {
VARIABLES_MAP = {
'ansible_ssh_user': 'ansible_ssh_user',
'deployment_type': 'deployment_type',
+ 'variant_subtype': 'deployment_subtype',
'master_routingconfig_subdomain': 'openshift_master_default_subdomain',
'proxy_http': 'openshift_http_proxy',
'proxy_https': 'openshift_https_proxy',
@@ -128,6 +129,8 @@ def write_inventory_vars(base_inventory, multiple_masters, lb):
ver = find_variant(CFG.settings['variant'],
version=CFG.settings.get('variant_version', None))[1]
base_inventory.write('deployment_type={}\n'.format(ver.ansible_key))
+ if getattr(ver, 'variant_subtype', False):
+ base_inventory.write('deployment_subtype={}\n'.format(ver.deployment_subtype))
if 'OO_INSTALL_ADDITIONAL_REGISTRIES' in os.environ:
base_inventory.write('openshift_docker_additional_registries={}\n'.format(
diff --git a/utils/src/ooinstall/variants.py b/utils/src/ooinstall/variants.py
index c723c7e61..8f82655fd 100644
--- a/utils/src/ooinstall/variants.py
+++ b/utils/src/ooinstall/variants.py
@@ -16,10 +16,11 @@ installer_log = logging.getLogger('installer')
class Version(object):
- def __init__(self, name, ansible_key):
+ def __init__(self, name, ansible_key, subtype=''):
self.name = name # i.e. 3.0, 3.1
self.ansible_key = ansible_key
+ self.subtype = subtype
class Variant(object):
@@ -43,6 +44,12 @@ OSE = Variant('openshift-enterprise', 'OpenShift Container Platform',
]
)
+REG = Variant('openshift-enterprise', 'Registry',
+ [
+ Version('3.2', 'openshift-enterprise', 'registry'),
+ ]
+)
+
origin = Variant('origin', 'OpenShift Origin',
[
Version('1.2', 'origin'),
@@ -58,8 +65,8 @@ LEGACY = Variant('openshift-enterprise', 'OpenShift Container Platform',
)
# Ordered list of variants we can install, first is the default.
-SUPPORTED_VARIANTS = (OSE, origin, LEGACY)
-DISPLAY_VARIANTS = (OSE, )
+SUPPORTED_VARIANTS = (OSE, REG, origin, LEGACY)
+DISPLAY_VARIANTS = (OSE, REG,)
def find_variant(name, version=None):