From c35c8f3e8369eb3d2ab7675c30e8d258eccd6a18 Mon Sep 17 00:00:00 2001 From: Tomas Sedovic Date: Thu, 4 Jan 2018 16:15:44 +0100 Subject: Allow using server names in openstack dynamic inv When deploying on OpenStack with internal DNS configured, this will set `openshift_hostname` to the Nova server name instead of its IP address. Without those two matching, the OpenStack cloud provider configuration will fail and the OpenShift nodes will not start. --- roles/openshift_openstack/templates/heat_stack_server.yaml.j2 | 3 +++ 1 file changed, 3 insertions(+) (limited to 'roles/openshift_openstack') diff --git a/roles/openshift_openstack/templates/heat_stack_server.yaml.j2 b/roles/openshift_openstack/templates/heat_stack_server.yaml.j2 index a829da34f..1e73c9e1c 100644 --- a/roles/openshift_openstack/templates/heat_stack_server.yaml.j2 +++ b/roles/openshift_openstack/templates/heat_stack_server.yaml.j2 @@ -212,6 +212,9 @@ resources: host-type: { get_param: type } sub-host-type: { get_param: subtype } node_labels: { get_param: node_labels } +{% if openshift_openstack_dns_nameservers %} + openshift_hostname: { get_param: name } +{% endif %} scheduler_hints: { get_param: scheduler_hints } {% if use_trunk_ports|default(false)|bool %} -- cgit v1.2.1