summaryrefslogtreecommitdiffstats
path: root/playbooks/gce/openshift-master/config.yml
diff options
context:
space:
mode:
Diffstat (limited to 'playbooks/gce/openshift-master/config.yml')
-rw-r--r--playbooks/gce/openshift-master/config.yml13
1 files changed, 11 insertions, 2 deletions
diff --git a/playbooks/gce/openshift-master/config.yml b/playbooks/gce/openshift-master/config.yml
index a74250d13..5581e8401 100644
--- a/playbooks/gce/openshift-master/config.yml
+++ b/playbooks/gce/openshift-master/config.yml
@@ -1,5 +1,4 @@
----
-- name: "populate oo_hosts_to_config host group if needed"
+- name: "master/config.yml, populate oo_hosts_to_config host group if needed"
hosts: localhost
gather_facts: no
tasks:
@@ -13,6 +12,16 @@
connection: ssh
user: root
+- name: "Retrieve public ip"
+ hosts: oo_hosts_to_config
+ connection: ssh
+ user: root
+ gather_facts: yes
+ tasks:
+ - command: 'curl "http://metadata.google.internal/computeMetadata/v1/instance/network-interfaces/0/access-configs/0/external-ip" -H "Metadata-Flavor: Google"'
+ register: output
+ - set_fact: gce_public_ip="{{ output.stdout }}"
+
- name: "Set Origin specific facts on localhost (for later use)"
hosts: localhost
gather_facts: no