From dd10b8a27c269098f8fff3a894cc99fdf2188073 Mon Sep 17 00:00:00 2001 From: Xavier Lange Date: Wed, 25 Jan 2017 14:34:54 -0800 Subject: [PATCH 1/2] Bug fix: support kilo's keystone requirement for domain-name, extracts from ENV var --- roles/kubernetes/preinstall/defaults/main.yml | 1 + .../kubernetes/preinstall/templates/openstack-cloud-config.j2 | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/roles/kubernetes/preinstall/defaults/main.yml b/roles/kubernetes/preinstall/defaults/main.yml index 59076c204..1bf697aee 100644 --- a/roles/kubernetes/preinstall/defaults/main.yml +++ b/roles/kubernetes/preinstall/defaults/main.yml @@ -28,6 +28,7 @@ openstack_username: "{{ lookup('env','OS_USERNAME') }}" openstack_password: "{{ lookup('env','OS_PASSWORD') }}" openstack_region: "{{ lookup('env','OS_REGION_NAME') }}" openstack_tenant_id: "{{ lookup('env','OS_TENANT_ID')|default(lookup('env','OS_PROJECT_ID'),true) }}" +openstack_domain_name: "{{ lookup('env','OS_USER_DOMAIN_NAME') }}" # Container Linux by CoreOS cloud init config file to define /etc/resolv.conf content # for hostnet pods and infra needs diff --git a/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 b/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 index 77668f295..acad80a1a 100644 --- a/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 +++ b/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 @@ -3,4 +3,5 @@ auth-url={{ openstack_auth_url }} username={{ openstack_username }} password={{ openstack_password }} region={{ openstack_region }} -tenant-id={{ openstack_tenant_id }} \ No newline at end of file +tenant-id={{ openstack_tenant_id }} +domain-name={{ openstack_domain_name }} From 30a9899262175ae03c1909eff0180d458aeead97 Mon Sep 17 00:00:00 2001 From: Brad Beam Date: Mon, 27 Feb 2017 21:19:27 -0600 Subject: [PATCH 2/2] Making openstack domain name optional --- roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 b/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 index acad80a1a..8f13fc6b9 100644 --- a/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 +++ b/roles/kubernetes/preinstall/templates/openstack-cloud-config.j2 @@ -4,4 +4,6 @@ username={{ openstack_username }} password={{ openstack_password }} region={{ openstack_region }} tenant-id={{ openstack_tenant_id }} +{% if openstack_domain_name is defined and openstack_domain_name != "" %} domain-name={{ openstack_domain_name }} +{% endif %}