From da8c0f218ae70f5238a50ed26e365dc8de350fd1 Mon Sep 17 00:00:00 2001 From: vnaumov Date: Thu, 27 Sep 2018 19:51:30 +0400 Subject: [PATCH] Define floating ip's into k8s-config ssl context to avoid https://github.com/kubernetes-incubator/kubespray/issues/1430 --- kqueen/engines/openstack_kubespray.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/kqueen/engines/openstack_kubespray.py b/kqueen/engines/openstack_kubespray.py index b4955ad0..45d7db3e 100644 --- a/kqueen/engines/openstack_kubespray.py +++ b/kqueen/engines/openstack_kubespray.py @@ -478,9 +478,17 @@ def _create_group_vars(self, metadata): kubespray_vars["openstack_lbaas_subnet_id"] = metadata["resources"]["subnet_id"] kubespray_vars["openstack_lbaas_floating_network_id"] = metadata["resources"]["ext_net_id"] # See https://github.com/kubernetes-incubator/kubespray/issues/2141 - # Set this variable to true to get rid of this issue``` + # Set this variable to true to get rid of this issue kubespray_vars["volume_cross_zone_attachment"] = True + + # See https://github.com/kubernetes-incubator/kubespray/issues/1430 + # Set all fips in this var to get rid of kubectl ssl-certs issue + ssl_fips = [master["fip"] for master in metadata["resources"]["masters"]] + if ssl_fips: + kubespray_vars["supplementary_addresses_in_ssl_keys"] = ssl_fips + + image_var_names = [var_name for var_name in dir(config) if var_name.endswith(('_IMAGE_REPO', '_IMAGE_TAG'))] image_variables = {k.lower(): getattr(config, k) for k in image_var_names} kubespray_vars.update(image_variables)