summaryrefslogtreecommitdiffstats
path: root/playbooks
diff options
context:
space:
mode:
authorBogdan Dobrelya <bdobreli@redhat.com>2017-06-21 15:22:09 +0200
committerRyan Cook <rcook@redhat.com>2017-06-21 09:22:09 -0400
commit0908b25d45b9a5297ed341f136f8d42e59438553 (patch)
treec3b5b93f4b53cfd224614638fb057e2be1a27775 /playbooks
parent6457152be04098c7f765b322447006bdb052509f (diff)
downloadopenshift-0908b25d45b9a5297ed341f136f8d42e59438553.tar.gz
openshift-0908b25d45b9a5297ed341f136f8d42e59438553.tar.bz2
openshift-0908b25d45b9a5297ed341f136f8d42e59438553.tar.xz
openshift-0908b25d45b9a5297ed341f136f8d42e59438553.zip
Use cached facts, do not become for localhost (#484)
Prohibit sudoing for localhost played tasks, like DNS setup. Re-use cached facts to speed up deployment. Signed-off-by: Bogdan Dobrelya <bdobreli@redhat.com>
Diffstat (limited to 'playbooks')
-rw-r--r--playbooks/provisioning/openstack/post-provision-openstack.yml8
-rw-r--r--playbooks/provisioning/openstack/provision-openstack.yml4
2 files changed, 11 insertions, 1 deletions
diff --git a/playbooks/provisioning/openstack/post-provision-openstack.yml b/playbooks/provisioning/openstack/post-provision-openstack.yml
index 4e42c1c7f..918f9e065 100644
--- a/playbooks/provisioning/openstack/post-provision-openstack.yml
+++ b/playbooks/provisioning/openstack/post-provision-openstack.yml
@@ -1,6 +1,7 @@
---
# Assign hostnames
- hosts: cluster_hosts
+ gather_facts: False
become: true
pre_tasks:
- include: pre_tasks.yml
@@ -9,6 +10,7 @@
# Subscribe DNS Host to allow for configuration below
- hosts: dns
+ gather_facts: False
become: true
roles:
- role: subscription-manager
@@ -17,11 +19,14 @@
# Determine which DNS server(s) to use for our generated records
- hosts: localhost
+ gather_facts: False
+ become: False
roles:
- dns-server-detect
# Build the DNS Server Views and Configure DNS Server(s)
- hosts: dns
+ gather_facts: False
become: true
pre_tasks:
- include: pre_tasks.yml
@@ -32,6 +37,8 @@
# Build and process DNS Records
- hosts: localhost
+ gather_facts: False
+ become: False
pre_tasks:
- include: pre_tasks.yml
- name: "Generate dns records"
@@ -41,6 +48,7 @@
# OpenShift Pre-Requisites
- hosts: OSEv3
+ gather_facts: False
become: true
tasks:
- name: "Edit /etc/resolv.conf on masters/nodes"
diff --git a/playbooks/provisioning/openstack/provision-openstack.yml b/playbooks/provisioning/openstack/provision-openstack.yml
index c7ad782c9..a2cf7b110 100644
--- a/playbooks/provisioning/openstack/provision-openstack.yml
+++ b/playbooks/provisioning/openstack/provision-openstack.yml
@@ -1,6 +1,7 @@
---
- hosts: localhost
gather_facts: True
+ become: False
pre_tasks:
- include: pre_tasks.yml
roles:
@@ -31,12 +32,13 @@
- name: Refresh Server inventory
hosts: localhost
connection: local
+ become: False
gather_facts: False
tasks:
- meta: refresh_inventory
- hosts: cluster_hosts
- gather_facts: false
+ gather_facts: True
tasks:
- name: Debug hostvar
debug: