Browse Source

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.
Tomas Sedovic 7 years ago
parent
commit
cc67080cae
1 changed files with 1 additions and 0 deletions
  1. 1 0
      roles/static_inventory/templates/inventory.j2

+ 1 - 0
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 %}