summaryrefslogtreecommitdiffstats
path: root/playbooks/provisioning
diff options
context:
space:
mode:
Diffstat (limited to 'playbooks/provisioning')
-rw-r--r--playbooks/provisioning/openstack/post-provision-openstack.yml22
-rw-r--r--playbooks/provisioning/openstack/pre-install.yml1
2 files changed, 12 insertions, 11 deletions
diff --git a/playbooks/provisioning/openstack/post-provision-openstack.yml b/playbooks/provisioning/openstack/post-provision-openstack.yml
index d65e075b8..e1faf14eb 100644
--- a/playbooks/provisioning/openstack/post-provision-openstack.yml
+++ b/playbooks/provisioning/openstack/post-provision-openstack.yml
@@ -2,25 +2,30 @@
# Assign hostnames
- hosts: cluster_hosts
+ become: true
pre_tasks:
- - include: roles/common/pre_tasks/pre_tasks.yml
+ - include: pre_tasks.yml
roles:
- role: hostnames
# Subscribe DNS Host to allow for configuration below
- hosts: dns
+ become: true
roles:
- - { role: subscription-manager, when: hostvars.localhost.rhsm_register, tags: 'subscription-manager', ansible_sudo: true }
+ - role: subscription-manager
+ when: hostvars.localhost.rhsm_register
+ tags: 'subscription-manager'
# Determine which DNS server(s) to use for our generated records
- hosts: localhost
- roles:
+ roles:
- dns-server-detect
# Build the DNS Server Views and Configure DNS Server(s)
- hosts: dns
+ become: true
pre_tasks:
- - include: roles/common/pre_tasks/pre_tasks.yml
+ - include: pre_tasks.yml
- name: "Generate dns-server views"
include: openstack_dns_views.yml
roles:
@@ -29,20 +34,15 @@
# Build and process DNS Records
- hosts: localhost
pre_tasks:
- - include: roles/common/pre_tasks/pre_tasks.yml
+ - include: pre_tasks.yml
- name: "Generate dns records"
include: openstack_dns_records.yml
roles:
- role: dns
-# Use newly configured DNS server for this container ...
-- hosts: localhost
- tasks:
- - name: "Edit /etc/resolv.conf in container"
- shell: "sed '0,/.*nameserver.*/s/.*nameserver.*/nameserver {{ public_dns_server }} \\n&/' /etc/resolv.conf > /tmp/resolv.conf && /bin/cp -f /tmp/resolv.conf /etc/resolv.conf"
-
# OpenShift Pre-Requisites
- hosts: OSEv3
+ become: true
tasks:
- name: "Edit /etc/resolv.conf on masters/nodes"
lineinfile:
diff --git a/playbooks/provisioning/openstack/pre-install.yml b/playbooks/provisioning/openstack/pre-install.yml
index 8225287f9..4da007a16 100644
--- a/playbooks/provisioning/openstack/pre-install.yml
+++ b/playbooks/provisioning/openstack/pre-install.yml
@@ -8,6 +8,7 @@
# - other prep (install additional packages, etc.)
#
- hosts: OSEv3
+ become: true
roles:
- { role: subscription-manager, when: hostvars.localhost.rhsm_register, tags: 'subscription-manager', ansible_sudo: true }
- { role: docker, tags: 'docker' }