summaryrefslogtreecommitdiffstats
path: root/roles/static_inventory
diff options
context:
space:
mode:
authorTomas Sedovic <tomas@sedovic.cz>2017-07-25 15:17:20 +0200
committerGitHub <noreply@github.com>2017-07-25 15:17:20 +0200
commitcc67080cae89834c1b0a531870b5ee6425b0b2ac (patch)
tree541ba28ce15ae660cbec69c76d310a2593ed3868 /roles/static_inventory
parentdc1ccbbaed94b2b6831f03c130a9be3c139ae9de (diff)
downloadopenshift-cc67080cae89834c1b0a531870b5ee6425b0b2ac.tar.gz
openshift-cc67080cae89834c1b0a531870b5ee6425b0b2ac.tar.bz2
openshift-cc67080cae89834c1b0a531870b5ee6425b0b2ac.tar.xz
openshift-cc67080cae89834c1b0a531870b5ee6425b0b2ac.zip
Set openshift_hostname explicitly for openstack (#579)
This fixes a regression caused by the move to the static inventory. The nodes in `oc get nodes` should be (and had been) identified by their hostnames (e.g. master-0.openshift.example.com), but are now using their internal IP addresses instead.
Diffstat (limited to 'roles/static_inventory')
-rw-r--r--roles/static_inventory/templates/inventory.j21
1 files changed, 1 insertions, 0 deletions
diff --git a/roles/static_inventory/templates/inventory.j2 b/roles/static_inventory/templates/inventory.j2
index 9d129cf10..464726a0b 100644
--- a/roles/static_inventory/templates/inventory.j2
+++ b/roles/static_inventory/templates/inventory.j2
@@ -12,6 +12,7 @@
%} public_v4={{ hostvars[host]['public_v4'] }}{% endif %}
{% if 'ansible_private_key_file' in hostvars[host]
%} ansible_private_key_file={{ hostvars[host]['ansible_private_key_file'] }}{% endif %}
+ openshift_hostname={{ host }}
{% endif %}
{% endfor %}