diff options
author | Tim Rozet <trozet@redhat.com> | 2017-12-04 11:20:23 -0500 |
---|---|---|
committer | Tim Rozet <trozet@redhat.com> | 2018-03-16 14:51:33 -0400 |
commit | f6dbb3929d904b4d5a9ee01f8270051e29ac1ec3 (patch) | |
tree | f2490665c2febe0ebc463714f5375483bfca9710 /apex/undercloud/undercloud.py | |
parent | a008f8394e07f1b82d5bf7288f46c63252f6084f (diff) |
Enables containerized overcloud deployments
Changes Include:
- For upstream deployments, Docker local registry will be updated with
latest current RDO containers, regular deployments will use latest
stable
- Upstream container images will then be patched/modified and then
re-uploaded into local docker registry with 'apex' tag
- Deployment command modified to deploy with containers
- Adds a --no-fetch deployment argument to disable pulling latest
from upstream, and instead using what already exists in cache
- Moves Undercloud NAT setup to just after undercloud is installed.
This provides internet during overcloud install which is now
required for upstream container deployments.
- Creates loop device for Ceph deployment when no device is
provided in deploy settings (for container deployment only)
- Updates NIC J2 template to use the new format in OOO since
the os-apply-config method is now deprecated in > Queens
JIRA: APEX-566
JIRA: APEX-549
Change-Id: I0652c194c059b915a942ac7401936e8f5c69d1fa
Signed-off-by: Tim Rozet <trozet@redhat.com>
Diffstat (limited to 'apex/undercloud/undercloud.py')
-rw-r--r-- | apex/undercloud/undercloud.py | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/apex/undercloud/undercloud.py b/apex/undercloud/undercloud.py index 915c85f3..e799d371 100644 --- a/apex/undercloud/undercloud.py +++ b/apex/undercloud/undercloud.py @@ -115,13 +115,14 @@ class Undercloud: "correctly") def configure(self, net_settings, deploy_settings, - playbook, apex_temp_dir): + playbook, apex_temp_dir, virtual_oc=False): """ Configures undercloud VM :param net_settings: Network settings for deployment :param deploy_settings: Deployment settings for deployment :param playbook: playbook to use to configure undercloud :param apex_temp_dir: temporary apex directory to hold configs/logs + :param virtual_oc: Boolean to determine if overcloud is virt :return: None """ @@ -130,6 +131,7 @@ class Undercloud: ansible_vars = Undercloud.generate_config(net_settings, deploy_settings) ansible_vars['apex_temp_dir'] = apex_temp_dir + ansible_vars['virtual_overcloud'] = virtual_oc try: utils.run_ansible(ansible_vars, playbook, host=self.ip, user='stack') @@ -239,7 +241,16 @@ class Undercloud: "prefix": str(ns_external['cidr']).split('/')[1], "enabled": ns_external['enabled'] } - + # TODO(trozet): clean this logic up and merge with above + if 'external' in ns.enabled_network_list: + nat_cidr = ns_external['cidr'] + else: + nat_cidr = ns['networks']['admin']['cidr'] + config['nat_cidr'] = str(nat_cidr) + if nat_cidr.version == 6: + config['nat_network_ipv6'] = True + else: + config['nat_network_ipv6'] = False config['http_proxy'] = ns.get('http_proxy', '') config['https_proxy'] = ns.get('https_proxy', '') |