summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.tito/packages/openshift-ansible2
-rw-r--r--openshift-ansible.spec39
-rw-r--r--playbooks/common/openshift-cluster/tasks/set_etcd_launch_facts.yml13
-rw-r--r--playbooks/common/openshift-cluster/tasks/set_master_launch_facts.yml13
-rw-r--r--playbooks/common/openshift-cluster/tasks/set_node_launch_facts.yml15
-rw-r--r--playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml2
-rw-r--r--playbooks/common/openshift-cluster/upgrades/post_control_plane.yml4
-rw-r--r--playbooks/common/openshift-cluster/upgrades/upgrade_control_plane.yml4
-rw-r--r--playbooks/init/facts.yml5
-rw-r--r--playbooks/openshift-glusterfs/config.yml4
-rw-r--r--playbooks/openshift-glusterfs/private/registry.yml2
-rw-r--r--playbooks/openshift-glusterfs/registry.yml4
-rw-r--r--playbooks/openshift-management/add_container_provider.yml4
-rw-r--r--playbooks/openshift-management/config.yml4
-rw-r--r--playbooks/openshift-management/uninstall.yml2
-rw-r--r--playbooks/openshift-master/additional_config.yml4
-rw-r--r--playbooks/openshift-master/certificates.yml4
-rw-r--r--playbooks/openshift-master/config.yml4
-rw-r--r--playbooks/openshift-master/private/additional_config.yml2
-rw-r--r--playbooks/openshift-master/private/config.yml4
-rw-r--r--playbooks/openshift-master/private/restart.yml9
-rw-r--r--playbooks/openshift-master/private/scaleup.yml12
-rw-r--r--playbooks/openshift-master/private/tasks/restart_hosts.yml (renamed from playbooks/openshift-master/private/restart_hosts.yml)0
-rw-r--r--playbooks/openshift-master/private/tasks/restart_services.yml (renamed from playbooks/openshift-master/private/restart_services.yml)0
-rw-r--r--playbooks/openshift-master/restart.yml4
-rw-r--r--playbooks/openshift-master/scaleup.yml6
-rw-r--r--playbooks/openshift-node/certificates.yml4
-rw-r--r--playbooks/openshift-node/config.yml4
-rw-r--r--playbooks/openshift-node/network_manager.yml4
-rw-r--r--playbooks/openshift-node/private/additional_config.yml2
-rw-r--r--playbooks/openshift-node/private/config.yml14
-rw-r--r--playbooks/openshift-node/private/image_prep.yml14
-rw-r--r--playbooks/openshift-node/private/network_manager.yml2
-rw-r--r--playbooks/openshift-node/restart.yml4
-rw-r--r--playbooks/openshift-node/scaleup.yml6
-rw-r--r--roles/cockpit/tasks/main.yml3
-rw-r--r--roles/contiv/tasks/main.yml6
-rw-r--r--roles/contiv/tasks/netmaster.yml8
-rw-r--r--roles/contiv/tasks/netplugin.yml6
-rw-r--r--roles/contiv/tasks/ovs.yml2
-rw-r--r--roles/contiv/tasks/packageManagerInstall.yml2
-rw-r--r--roles/contiv_facts/tasks/main.yml4
-rw-r--r--roles/docker/tasks/main.yml9
-rw-r--r--roles/docker/tasks/package_docker.yml5
-rw-r--r--roles/docker/tasks/systemcontainer_crio.yml6
-rw-r--r--roles/kuryr/tasks/master.yaml4
-rw-r--r--roles/nuage_master/tasks/main.yaml7
-rw-r--r--roles/nuage_node/tasks/main.yaml7
-rw-r--r--roles/openshift_cloud_provider/tasks/main.yml6
-rw-r--r--roles/openshift_excluder/tasks/disable.yml10
-rw-r--r--roles/openshift_excluder/tasks/enable.yml4
-rw-r--r--roles/openshift_excluder/tasks/main.yml2
-rw-r--r--roles/openshift_excluder/tasks/verify_upgrade.yml4
-rw-r--r--roles/openshift_master/defaults/main.yml2
-rw-r--r--roles/openshift_master/tasks/main.yml19
-rw-r--r--roles/openshift_master/tasks/systemd_units.yml10
-rw-r--r--roles/openshift_master/tasks/upgrade.yml10
-rw-r--r--roles/openshift_master_cluster/tasks/main.yml2
-rw-r--r--roles/openshift_node/defaults/main.yml1
-rw-r--r--roles/openshift_node/tasks/bootstrap.yml3
-rw-r--r--roles/openshift_node/tasks/config.yml5
-rw-r--r--roles/openshift_node/tasks/main.yml21
-rw-r--r--roles/openshift_node/tasks/systemd_units.yml18
-rw-r--r--roles/openshift_node/tasks/upgrade.yml12
-rw-r--r--roles/openshift_node/tasks/upgrade/containerized_node_upgrade.yml2
-rw-r--r--roles/openshift_node_dnsmasq/tasks/main.yml4
-rw-r--r--roles/openshift_node_dnsmasq/tasks/no-network-manager.yml2
-rw-r--r--roles/openshift_node_group/tasks/main.yml2
-rw-r--r--roles/openshift_prometheus/README.md4
-rw-r--r--roles/openshift_prometheus/defaults/main.yaml4
-rw-r--r--roles/openshift_prometheus/tasks/install_prometheus.yaml3
-rw-r--r--roles/openshift_storage_glusterfs/files/v3.7/glusterblock-provisioner.yml1
-rw-r--r--roles/openshift_storage_glusterfs/files/v3.8/glusterblock-provisioner.yml1
-rw-r--r--tox.ini2
74 files changed, 218 insertions, 225 deletions
diff --git a/.tito/packages/openshift-ansible b/.tito/packages/openshift-ansible
index bde889621..9db0b5c98 100644
--- a/.tito/packages/openshift-ansible
+++ b/.tito/packages/openshift-ansible
@@ -1 +1 @@
-3.8.0-0.9.0 ./
+3.8.0-0.13.0 ./
diff --git a/openshift-ansible.spec b/openshift-ansible.spec
index 313af17be..418241aa1 100644
--- a/openshift-ansible.spec
+++ b/openshift-ansible.spec
@@ -10,7 +10,7 @@
Name: openshift-ansible
Version: 3.8.0
-Release: 0.9.0%{?dist}
+Release: 0.13.0%{?dist}
Summary: Openshift and Atomic Enterprise Ansible
License: ASL 2.0
URL: https://github.com/openshift/openshift-ansible
@@ -285,6 +285,43 @@ Atomic OpenShift Utilities includes
%changelog
+* Thu Nov 23 2017 Jenkins CD Merge Bot <smunilla@redhat.com> 3.8.0-0.13.0
+-
+
+* Thu Nov 23 2017 Jenkins CD Merge Bot <smunilla@redhat.com> 3.8.0-0.12.0
+-
+
+* Thu Nov 23 2017 Jenkins CD Merge Bot <smunilla@redhat.com> 3.8.0-0.11.0
+-
+
+* Thu Nov 23 2017 Jenkins CD Merge Bot <smunilla@redhat.com> 3.8.0-0.10.0
+- tox.ini: simplify unit test reqs (lmeyer@redhat.com)
+- Remove unused task files (rteague@redhat.com)
+- Playbook Consolidation - openshift-provisioners (rteague@redhat.com)
+- Include Deprecation - openshift-prometheus (rteague@redhat.com)
+- Include Deprecation - openshift-node (rteague@redhat.com)
+- Include Deprecation - openshift-management (rteague@redhat.com)
+- Include Deprecation - openshift-glusterfs (rteague@redhat.com)
+- Include Deprecation - openshift-master (rteague@redhat.com)
+- Include Deprecation - openshift-hosted (rteague@redhat.com)
+- Playbook Consolidation - openshift-service-catalog (rteague@redhat.com)
+- Include Deprecation - openshift-nfs (rteague@redhat.com)
+- Include Deprecation - openshift-metrics (rteague@redhat.com)
+- Include Deprecation - openshift-etcd (rteague@redhat.com)
+- Fix system_images_registry variable (mgugino@redhat.com)
+- Include Deprecation - openshift-loadbalancer (rteague@redhat.com)
+- Include Deprecation - openshift-checks (rteague@redhat.com)
+- Playbook Consolidation - openshift-management (rteague@redhat.com)
+- Playbook Consolidation - openshift-master (rteague@redhat.com)
+- Playbook Consolidation - openshift-hosted (rteague@redhat.com)
+- Place-holder for prerequisites.yml (mgugino@redhat.com)
+- Cleanup etcd runtime variable. (mgugino@redhat.com)
+- Fix uninstall option for prometheus (zgalor@redhat.com)
+- Playbook Consolidation - openshift-glusterfs (rteague@redhat.com)
+- Playbook Consolidation - openshift-metrics (rteague@redhat.com)
+- Playbook Consolidation - openshift-loadbalancer (rteague@redhat.com)
+- hosted_registry: clean up tmp mount point and fstab (dusty@dustymabe.com)
+
* Wed Nov 22 2017 Jenkins CD Merge Bot <smunilla@redhat.com> 3.8.0-0.9.0
- Fix node system container var (mgugino@redhat.com)
- Add temporary playbook for CI test functionality (rteague@redhat.com)
diff --git a/playbooks/common/openshift-cluster/tasks/set_etcd_launch_facts.yml b/playbooks/common/openshift-cluster/tasks/set_etcd_launch_facts.yml
deleted file mode 100644
index eb118365a..000000000
--- a/playbooks/common/openshift-cluster/tasks/set_etcd_launch_facts.yml
+++ /dev/null
@@ -1,13 +0,0 @@
----
-- set_fact: k8s_type="etcd"
-
-- name: Generate etcd instance names(s)
- set_fact:
- scratch_name: "{{ openshift_cluster_id | default('default') }}-{{ k8s_type }}-{{ '%05x' | format(1048576 | random) }}"
- register: etcd_names_output
- with_sequence: count={{ num_etcd }}
-
-- set_fact:
- etcd_names: "{{ etcd_names_output.results | default([])
- | oo_collect('ansible_facts')
- | oo_collect('scratch_name') }}"
diff --git a/playbooks/common/openshift-cluster/tasks/set_master_launch_facts.yml b/playbooks/common/openshift-cluster/tasks/set_master_launch_facts.yml
deleted file mode 100644
index 783f70f50..000000000
--- a/playbooks/common/openshift-cluster/tasks/set_master_launch_facts.yml
+++ /dev/null
@@ -1,13 +0,0 @@
----
-- set_fact: k8s_type="master"
-
-- name: Generate master instance names(s)
- set_fact:
- scratch_name: "{{ openshift_cluster_id | default('default') }}-{{ k8s_type }}-{{ '%05x' | format(1048576 | random) }}"
- register: master_names_output
- with_sequence: count={{ num_masters }}
-
-- set_fact:
- master_names: "{{ master_names_output.results | default([])
- | oo_collect('ansible_facts')
- | oo_collect('scratch_name') }}"
diff --git a/playbooks/common/openshift-cluster/tasks/set_node_launch_facts.yml b/playbooks/common/openshift-cluster/tasks/set_node_launch_facts.yml
deleted file mode 100644
index c103e40a9..000000000
--- a/playbooks/common/openshift-cluster/tasks/set_node_launch_facts.yml
+++ /dev/null
@@ -1,15 +0,0 @@
----
-- set_fact: k8s_type=node
-- set_fact: sub_host_type="{{ type }}"
-- set_fact: number_nodes="{{ count }}"
-
-- name: Generate node instance names(s)
- set_fact:
- scratch_name: "{{ openshift_cluster_id | default('default') }}-{{ k8s_type }}-{{ sub_host_type }}-{{ '%05x' | format(1048576 | random) }}"
- register: node_names_output
- with_sequence: count={{ number_nodes }}
-
-- set_fact:
- node_names: "{{ node_names_output.results | default([])
- | oo_collect('ansible_facts')
- | oo_collect('scratch_name') }}"
diff --git a/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml b/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml
index 52345a9ba..2e3a7ae8b 100644
--- a/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml
+++ b/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml
@@ -16,7 +16,7 @@
changed_when: no
- name: Get current version of Docker
- command: "{{ repoquery_cmd }} --installed --qf '%{version}' docker"
+ command: "{{ repoquery_installed }} --qf '%{version}' docker"
register: curr_docker_version
retries: 4
until: curr_docker_version | succeeded
diff --git a/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml b/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml
index c634e0ab8..3aa9e0460 100644
--- a/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml
+++ b/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml
@@ -93,11 +93,11 @@
# not already exist. We could have potentially done a replace --force to
# create and update in one step.
- role: openshift_examples
- when: openshift_install_examples | default(true,true) | bool
+ when: openshift_install_examples | default(true) | bool
- openshift_hosted_templates
# Update the existing templates
- role: openshift_examples
- when: openshift_install_examples | default(true,true) | bool
+ when: openshift_install_examples | default(true) | bool
registry_url: "{{ openshift.master.registry_url }}"
openshift_examples_import_command: replace
- role: openshift_hosted_templates
diff --git a/playbooks/common/openshift-cluster/upgrades/upgrade_control_plane.yml b/playbooks/common/openshift-cluster/upgrades/upgrade_control_plane.yml
index 52438bdc4..d08c6e940 100644
--- a/playbooks/common/openshift-cluster/upgrades/upgrade_control_plane.yml
+++ b/playbooks/common/openshift-cluster/upgrades/upgrade_control_plane.yml
@@ -85,10 +85,10 @@
- include: "{{ openshift_master_upgrade_hook }}"
when: openshift_master_upgrade_hook is defined
- - include: ../../../openshift-master/private/restart_hosts.yml
+ - include: ../../../openshift-master/private/tasks/restart_hosts.yml
when: openshift.common.rolling_restart_mode == 'system'
- - include: ../../../openshift-master/private/restart_services.yml
+ - include: ../../../openshift-master/private/tasks/restart_services.yml
when: openshift.common.rolling_restart_mode == 'services'
# Run the post-upgrade hook if defined:
diff --git a/playbooks/init/facts.yml b/playbooks/init/facts.yml
index 7439313b7..820561b2b 100644
--- a/playbooks/init/facts.yml
+++ b/playbooks/init/facts.yml
@@ -29,8 +29,6 @@
- name: initialize_facts set fact for containerized and l_is_*_system_container
set_fact:
l_is_containerized: "{{ (l_is_atomic | bool) or (containerized | default(false) | bool) }}"
- l_is_openvswitch_system_container: "{{ (openshift_use_openvswitch_system_container | default(openshift_use_system_containers | default(false)) | bool) }}"
- l_is_master_system_container: "{{ (openshift_use_master_system_container | default(openshift_use_system_containers | default(false)) | bool) }}"
# TODO: Should this be moved into health checks??
# Seems as though any check that happens with a corresponding fail should move into health_checks
@@ -113,8 +111,6 @@
hostname: "{{ openshift_hostname | default(None) }}"
ip: "{{ openshift_ip | default(None) }}"
is_containerized: "{{ l_is_containerized | default(None) }}"
- is_openvswitch_system_container: "{{ l_is_openvswitch_system_container | default(false) }}"
- is_master_system_container: "{{ l_is_master_system_container | default(false) }}"
public_hostname: "{{ openshift_public_hostname | default(None) }}"
public_ip: "{{ openshift_public_ip | default(None) }}"
portal_net: "{{ openshift_portal_net | default(openshift_master_portal_net) | default(None) }}"
@@ -139,6 +135,7 @@
- name: initialize_facts set_fact repoquery command
set_fact:
repoquery_cmd: "{{ 'dnf repoquery --latest-limit 1 -d 0' if ansible_pkg_mgr == 'dnf' else 'repoquery --plugins' }}"
+ repoquery_installed: "{{ 'dnf repoquery --latest-limit 1 -d 0 --disableexcludes=all --installed' if ansible_pkg_mgr == 'dnf' else 'repoquery --plugins --installed' }}"
- name: initialize_facts set_fact on openshift_docker_hosted_registry_network
set_fact:
diff --git a/playbooks/openshift-glusterfs/config.yml b/playbooks/openshift-glusterfs/config.yml
index 8ee57ce8d..c7814207c 100644
--- a/playbooks/openshift-glusterfs/config.yml
+++ b/playbooks/openshift-glusterfs/config.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/config.yml
+- import_playbook: private/config.yml
diff --git a/playbooks/openshift-glusterfs/private/registry.yml b/playbooks/openshift-glusterfs/private/registry.yml
index 80cf7529e..75c1f0300 100644
--- a/playbooks/openshift-glusterfs/private/registry.yml
+++ b/playbooks/openshift-glusterfs/private/registry.yml
@@ -1,5 +1,5 @@
---
-- include: config.yml
+- import_playbook: config.yml
- name: Initialize GlusterFS registry PV and PVC vars
hosts: oo_first_master
diff --git a/playbooks/openshift-glusterfs/registry.yml b/playbooks/openshift-glusterfs/registry.yml
index 21b59b9ef..5e3b18536 100644
--- a/playbooks/openshift-glusterfs/registry.yml
+++ b/playbooks/openshift-glusterfs/registry.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/registry.yml
+- import_playbook: private/registry.yml
diff --git a/playbooks/openshift-management/add_container_provider.yml b/playbooks/openshift-management/add_container_provider.yml
index 9f3834c6a..e0970f525 100644
--- a/playbooks/openshift-management/add_container_provider.yml
+++ b/playbooks/openshift-management/add_container_provider.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/evaluate_groups.yml
+- import_playbook: ../init/evaluate_groups.yml
-- include: private/add_container_provider.yml
+- import_playbook: private/add_container_provider.yml
diff --git a/playbooks/openshift-management/config.yml b/playbooks/openshift-management/config.yml
index 8ee57ce8d..c7814207c 100644
--- a/playbooks/openshift-management/config.yml
+++ b/playbooks/openshift-management/config.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/config.yml
+- import_playbook: private/config.yml
diff --git a/playbooks/openshift-management/uninstall.yml b/playbooks/openshift-management/uninstall.yml
index 3741f4739..c92ade786 100644
--- a/playbooks/openshift-management/uninstall.yml
+++ b/playbooks/openshift-management/uninstall.yml
@@ -1,2 +1,2 @@
---
-- include: private/uninstall.yml
+- import_playbook: private/uninstall.yml
diff --git a/playbooks/openshift-master/additional_config.yml b/playbooks/openshift-master/additional_config.yml
index e43e9e002..8105f7f88 100644
--- a/playbooks/openshift-master/additional_config.yml
+++ b/playbooks/openshift-master/additional_config.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/additional_config.yml
+- import_playbook: private/additional_config.yml
diff --git a/playbooks/openshift-master/certificates.yml b/playbooks/openshift-master/certificates.yml
index 0384877d9..7ae87c09a 100644
--- a/playbooks/openshift-master/certificates.yml
+++ b/playbooks/openshift-master/certificates.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/certificates.yml
+- import_playbook: private/certificates.yml
diff --git a/playbooks/openshift-master/config.yml b/playbooks/openshift-master/config.yml
index 8ee57ce8d..c7814207c 100644
--- a/playbooks/openshift-master/config.yml
+++ b/playbooks/openshift-master/config.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/config.yml
+- import_playbook: private/config.yml
diff --git a/playbooks/openshift-master/private/additional_config.yml b/playbooks/openshift-master/private/additional_config.yml
index 32f638d42..b7cfbe4e4 100644
--- a/playbooks/openshift-master/private/additional_config.yml
+++ b/playbooks/openshift-master/private/additional_config.yml
@@ -24,7 +24,7 @@
- role: openshift_project_request_template
when: openshift_project_request_template_manage
- role: openshift_examples
- when: openshift_install_examples | default(true, true) | bool
+ when: openshift_install_examples | default(true) | bool
registry_url: "{{ openshift.master.registry_url }}"
- role: openshift_hosted_templates
registry_url: "{{ openshift.master.registry_url }}"
diff --git a/playbooks/openshift-master/private/config.yml b/playbooks/openshift-master/private/config.yml
index 6b0fd6b7c..afb8d6bd1 100644
--- a/playbooks/openshift-master/private/config.yml
+++ b/playbooks/openshift-master/private/config.yml
@@ -11,7 +11,7 @@
status: "In Progress"
start: "{{ lookup('pipe', 'date +%Y%m%d%H%M%SZ') }}"
-- include: certificates.yml
+- import_playbook: certificates.yml
- name: Disable excluders
hosts: oo_masters_to_config
@@ -229,7 +229,7 @@
hosts: oo_masters
serial: 1
tasks:
- - include: tasks/wire_aggregator.yml
+ - include_tasks: tasks/wire_aggregator.yml
- name: Re-enable excluder if it was previously enabled
hosts: oo_masters_to_config
diff --git a/playbooks/openshift-master/private/restart.yml b/playbooks/openshift-master/private/restart.yml
index 4d73b8124..5cb284935 100644
--- a/playbooks/openshift-master/private/restart.yml
+++ b/playbooks/openshift-master/private/restart.yml
@@ -1,5 +1,5 @@
---
-- include: validate_restart.yml
+- import_playbook: validate_restart.yml
- name: Restart masters
hosts: oo_masters_to_config
@@ -7,13 +7,12 @@
openshift_master_ha: "{{ groups.oo_masters_to_config | length > 1 }}"
serial: 1
handlers:
- - include: ../../../roles/openshift_master/handlers/main.yml
- static: yes
+ - import_tasks: ../../../roles/openshift_master/handlers/main.yml
roles:
- openshift_facts
post_tasks:
- - include: restart_hosts.yml
+ - include_tasks: tasks/restart_hosts.yml
when: openshift_rolling_restart_mode | default('services') == 'system'
- - include: restart_services.yml
+ - include_tasks: tasks/restart_services.yml
when: openshift_rolling_restart_mode | default('services') == 'services'
diff --git a/playbooks/openshift-master/private/scaleup.yml b/playbooks/openshift-master/private/scaleup.yml
index 021399965..8229eccfa 100644
--- a/playbooks/openshift-master/private/scaleup.yml
+++ b/playbooks/openshift-master/private/scaleup.yml
@@ -44,14 +44,14 @@
delay: 1
changed_when: false
-- include: set_network_facts.yml
+- import_playbook: set_network_facts.yml
-- include: ../../openshift-etcd/private/certificates.yml
+- import_playbook: ../../openshift-etcd/private/certificates.yml
-- include: config.yml
+- import_playbook: config.yml
-- include: ../../openshift-loadbalancer/private/config.yml
+- import_playbook: ../../openshift-loadbalancer/private/config.yml
-- include: ../../openshift-node/private/certificates.yml
+- import_playbook: ../../openshift-node/private/certificates.yml
-- include: ../../openshift-node/private/config.yml
+- import_playbook: ../../openshift-node/private/config.yml
diff --git a/playbooks/openshift-master/private/restart_hosts.yml b/playbooks/openshift-master/private/tasks/restart_hosts.yml
index a5dbe0590..a5dbe0590 100644
--- a/playbooks/openshift-master/private/restart_hosts.yml
+++ b/playbooks/openshift-master/private/tasks/restart_hosts.yml
diff --git a/playbooks/openshift-master/private/restart_services.yml b/playbooks/openshift-master/private/tasks/restart_services.yml
index 4e1b3a3be..4e1b3a3be 100644
--- a/playbooks/openshift-master/private/restart_services.yml
+++ b/playbooks/openshift-master/private/tasks/restart_services.yml
diff --git a/playbooks/openshift-master/restart.yml b/playbooks/openshift-master/restart.yml
index 5e28e274e..041c1384d 100644
--- a/playbooks/openshift-master/restart.yml
+++ b/playbooks/openshift-master/restart.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/restart.yml
+- import_playbook: private/restart.yml
diff --git a/playbooks/openshift-master/scaleup.yml b/playbooks/openshift-master/scaleup.yml
index aa0dd8094..f717cd0e9 100644
--- a/playbooks/openshift-master/scaleup.yml
+++ b/playbooks/openshift-master/scaleup.yml
@@ -1,5 +1,5 @@
---
-- include: ../init/evaluate_groups.yml
+- import_playbook: ../init/evaluate_groups.yml
- name: Ensure there are new_masters or new_nodes
hosts: localhost
@@ -18,6 +18,6 @@
# Need a better way to do the above check for node without
# running evaluate_groups and init/main.yml
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/scaleup.yml
+- import_playbook: private/scaleup.yml
diff --git a/playbooks/openshift-node/certificates.yml b/playbooks/openshift-node/certificates.yml
index 0384877d9..7ae87c09a 100644
--- a/playbooks/openshift-node/certificates.yml
+++ b/playbooks/openshift-node/certificates.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/certificates.yml
+- import_playbook: private/certificates.yml
diff --git a/playbooks/openshift-node/config.yml b/playbooks/openshift-node/config.yml
index 8ee57ce8d..c7814207c 100644
--- a/playbooks/openshift-node/config.yml
+++ b/playbooks/openshift-node/config.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/config.yml
+- import_playbook: private/config.yml
diff --git a/playbooks/openshift-node/network_manager.yml b/playbooks/openshift-node/network_manager.yml
index c0900308c..88a93952d 100644
--- a/playbooks/openshift-node/network_manager.yml
+++ b/playbooks/openshift-node/network_manager.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/evaluate_groups.yml
+- import_playbook: ../init/evaluate_groups.yml
-- include: private/network_manager.yml
+- import_playbook: private/network_manager.yml
diff --git a/playbooks/openshift-node/private/additional_config.yml b/playbooks/openshift-node/private/additional_config.yml
index ac757397b..261e2048f 100644
--- a/playbooks/openshift-node/private/additional_config.yml
+++ b/playbooks/openshift-node/private/additional_config.yml
@@ -24,7 +24,7 @@
key: oo_nodes_use_{{ (openshift_use_kuryr | default(False)) | ternary('kuryr','nothing') }}
changed_when: False
-- include: etcd_client_config.yml
+- import_playbook: etcd_client_config.yml
vars:
openshift_node_scale_up_group: "oo_nodes_use_flannel:oo_nodes_use_calico:oo_nodes_use_contiv:oo_nodes_use_kuryr"
diff --git a/playbooks/openshift-node/private/config.yml b/playbooks/openshift-node/private/config.yml
index 28e3c1b1b..300a90371 100644
--- a/playbooks/openshift-node/private/config.yml
+++ b/playbooks/openshift-node/private/config.yml
@@ -11,19 +11,19 @@
status: "In Progress"
start: "{{ lookup('pipe', 'date +%Y%m%d%H%M%SZ') }}"
-- include: certificates.yml
+- import_playbook: certificates.yml
-- include: setup.yml
+- import_playbook: setup.yml
-- include: containerized_nodes.yml
+- import_playbook: containerized_nodes.yml
-- include: configure_nodes.yml
+- import_playbook: configure_nodes.yml
-- include: additional_config.yml
+- import_playbook: additional_config.yml
-- include: manage_node.yml
+- import_playbook: manage_node.yml
-- include: enable_excluders.yml
+- import_playbook: enable_excluders.yml
- name: Node Install Checkpoint End
hosts: all
diff --git a/playbooks/openshift-node/private/image_prep.yml b/playbooks/openshift-node/private/image_prep.yml
index 3c042acdc..b7ac27bda 100644
--- a/playbooks/openshift-node/private/image_prep.yml
+++ b/playbooks/openshift-node/private/image_prep.yml
@@ -1,21 +1,21 @@
---
- name: normalize groups
- include: ../../init/evaluate_groups.yml
+ import_playbook: ../../init/evaluate_groups.yml
- name: initialize the facts
- include: ../../init/facts.yml
+ import_playbook: ../../init/facts.yml
- name: initialize the repositories
- include: ../../init/repos.yml
+ import_playbook: ../../init/repos.yml
- name: run node config setup
- include: setup.yml
+ import_playbook: setup.yml
- name: run node config
- include: configure_nodes.yml
+ import_playbook: configure_nodes.yml
- name: Re-enable excluders
- include: enable_excluders.yml
+ import_playbook: enable_excluders.yml
- name: Remove any undesired artifacts from build
- include: clean_image.yml
+ import_playbook: clean_image.yml
diff --git a/playbooks/openshift-node/private/network_manager.yml b/playbooks/openshift-node/private/network_manager.yml
index c2efb0483..fffed4dfb 100644
--- a/playbooks/openshift-node/private/network_manager.yml
+++ b/playbooks/openshift-node/private/network_manager.yml
@@ -1,5 +1,5 @@
---
-- include: ../../init/evaluate_groups.yml
+- import_playbook: ../../init/evaluate_groups.yml
- name: Install and configure NetworkManager
hosts: oo_all_hosts
diff --git a/playbooks/openshift-node/restart.yml b/playbooks/openshift-node/restart.yml
index 5e28e274e..041c1384d 100644
--- a/playbooks/openshift-node/restart.yml
+++ b/playbooks/openshift-node/restart.yml
@@ -1,4 +1,4 @@
---
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/restart.yml
+- import_playbook: private/restart.yml
diff --git a/playbooks/openshift-node/scaleup.yml b/playbooks/openshift-node/scaleup.yml
index b4c39e37e..bdfd3d3e6 100644
--- a/playbooks/openshift-node/scaleup.yml
+++ b/playbooks/openshift-node/scaleup.yml
@@ -1,5 +1,5 @@
---
-- include: ../init/evaluate_groups.yml
+- import_playbook: ../init/evaluate_groups.yml
- name: Ensure there are new_nodes
hosts: localhost
@@ -16,6 +16,6 @@
# Need a better way to do the above check for node without
# running evaluate_groups and init/main.yml
-- include: ../init/main.yml
+- import_playbook: ../init/main.yml
-- include: private/config.yml
+- import_playbook: private/config.yml
diff --git a/roles/cockpit/tasks/main.yml b/roles/cockpit/tasks/main.yml
index 066ee3f3b..34754502a 100644
--- a/roles/cockpit/tasks/main.yml
+++ b/roles/cockpit/tasks/main.yml
@@ -1,7 +1,6 @@
---
- name: setup firewall
- include: firewall.yml
- static: yes
+ import_tasks: firewall.yml
- name: Install cockpit-ws
package: name={{ item }} state=present
diff --git a/roles/contiv/tasks/main.yml b/roles/contiv/tasks/main.yml
index 40a0f9e61..cb9196a71 100644
--- a/roles/contiv/tasks/main.yml
+++ b/roles/contiv/tasks/main.yml
@@ -5,10 +5,10 @@
recurse: yes
state: directory
-- include: download_bins.yml
+- include_tasks: download_bins.yml
-- include: netmaster.yml
+- include_tasks: netmaster.yml
when: contiv_role == "netmaster"
-- include: netplugin.yml
+- include_tasks: netplugin.yml
when: contiv_role == "netplugin"
diff --git a/roles/contiv/tasks/netmaster.yml b/roles/contiv/tasks/netmaster.yml
index cc52d3a43..6f15af8c2 100644
--- a/roles/contiv/tasks/netmaster.yml
+++ b/roles/contiv/tasks/netmaster.yml
@@ -1,8 +1,8 @@
---
-- include: netmaster_firewalld.yml
+- include_tasks: netmaster_firewalld.yml
when: has_firewalld
-- include: netmaster_iptables.yml
+- include_tasks: netmaster_iptables.yml
when: not has_firewalld and has_iptables
- name: Netmaster | Check is /etc/hosts file exists
@@ -70,8 +70,8 @@
state: started
register: netmaster_started
-- include: aci.yml
+- include_tasks: aci.yml
when: contiv_fabric_mode == "aci"
-- include: default_network.yml
+- include_tasks: default_network.yml
when: contiv_default_network == true
diff --git a/roles/contiv/tasks/netplugin.yml b/roles/contiv/tasks/netplugin.yml
index e861a2591..0b2f91bab 100644
--- a/roles/contiv/tasks/netplugin.yml
+++ b/roles/contiv/tasks/netplugin.yml
@@ -1,8 +1,8 @@
---
-- include: netplugin_firewalld.yml
+- include_tasks: netplugin_firewalld.yml
when: has_firewalld
-- include: netplugin_iptables.yml
+- include_tasks: netplugin_iptables.yml
when: has_iptables
- name: Netplugin | Ensure localhost entry correct in /etc/hosts
@@ -19,7 +19,7 @@
line: '::1 '
state: absent
-- include: ovs.yml
+- include_tasks: ovs.yml
when: netplugin_driver == "ovs"
- name: Netplugin | Create Netplugin bin symlink
diff --git a/roles/contiv/tasks/ovs.yml b/roles/contiv/tasks/ovs.yml
index 0c1b994c7..5c92e90e9 100644
--- a/roles/contiv/tasks/ovs.yml
+++ b/roles/contiv/tasks/ovs.yml
@@ -1,5 +1,5 @@
---
-- include: packageManagerInstall.yml
+- include_tasks: packageManagerInstall.yml
when: source_type == "packageManager"
tags:
- binary-update
diff --git a/roles/contiv/tasks/packageManagerInstall.yml b/roles/contiv/tasks/packageManagerInstall.yml
index e0d48e643..d5726476c 100644
--- a/roles/contiv/tasks/packageManagerInstall.yml
+++ b/roles/contiv/tasks/packageManagerInstall.yml
@@ -3,7 +3,7 @@
set_fact:
did_install: false
-- include: pkgMgrInstallers/centos-install.yml
+- include_tasks: pkgMgrInstallers/centos-install.yml
when: (ansible_os_family == "RedHat") and
not is_atomic
diff --git a/roles/contiv_facts/tasks/main.yml b/roles/contiv_facts/tasks/main.yml
index 7a4972fca..3267a4ab0 100644
--- a/roles/contiv_facts/tasks/main.yml
+++ b/roles/contiv_facts/tasks/main.yml
@@ -81,8 +81,8 @@
has_iptables: false
# collect information about what packages are installed
-- include: rpm.yml
+- include_tasks: rpm.yml
when: has_rpm
-- include: fedora-install.yml
+- include_tasks: fedora-install.yml
when: not is_atomic and ansible_distribution == "Fedora"
diff --git a/roles/docker/tasks/main.yml b/roles/docker/tasks/main.yml
index 55052b0a3..b02a74711 100644
--- a/roles/docker/tasks/main.yml
+++ b/roles/docker/tasks/main.yml
@@ -60,10 +60,11 @@
state: stopped
name: "{{ openshift.docker.service_name }}"
- - name: "Ensure {{ docker_alt_storage_path }} exists"
- file:
- path: "{{ docker_alt_storage_path }}"
- state: directory
+ - name: copy "{{ docker_default_storage_path }}" to "{{ docker_alt_storage_path }}"
+ command: "cp -r {{ docker_default_storage_path }} {{ docker_alt_storage_path }}"
+ register: results
+ failed_when:
+ - results.rc != 0
- name: "Set the selinux context on {{ docker_alt_storage_path }}"
command: "semanage fcontext -a -e {{ docker_default_storage_path }} {{ docker_alt_storage_path }}"
diff --git a/roles/docker/tasks/package_docker.yml b/roles/docker/tasks/package_docker.yml
index e6c3fe4d7..5437275a2 100644
--- a/roles/docker/tasks/package_docker.yml
+++ b/roles/docker/tasks/package_docker.yml
@@ -1,6 +1,6 @@
---
- name: Get current installed Docker version
- command: "{{ repoquery_cmd }} --installed --qf '%{version}' docker"
+ command: "{{ repoquery_installed }} --qf '%{version}' docker"
when: not openshift.common.is_atomic | bool
register: curr_docker_version
retries: 4
@@ -33,9 +33,10 @@
# Make sure Docker is installed, but does not update a running version.
# Docker upgrades are handled by a separate playbook.
+# Note: The curr_docker_version.stdout check can be removed when https://github.com/ansible/ansible/issues/33187 gets fixed.
- name: Install Docker
package: name=docker{{ '-' + docker_version if docker_version is defined else '' }} state=present
- when: not openshift.common.is_atomic | bool
+ when: not openshift.common.is_atomic | bool and not curr_docker_version | skipped and not curr_docker_version.stdout != ''
- block:
# Extend the default Docker service unit file when using iptables-services
diff --git a/roles/docker/tasks/systemcontainer_crio.yml b/roles/docker/tasks/systemcontainer_crio.yml
index 3e5bdf32c..17800d4e5 100644
--- a/roles/docker/tasks/systemcontainer_crio.yml
+++ b/roles/docker/tasks/systemcontainer_crio.yml
@@ -3,16 +3,10 @@
# TODO: Much of this file is shared with container engine tasks
- set_fact:
l_insecure_crio_registries: "{{ '\"{}\"'.format('\", \"'.join(l2_docker_insecure_registries)) }}"
- when: l2_docker_insecure_registries | bool
- set_fact:
l_crio_registries: "{{ l2_docker_additional_registries + ['docker.io'] }}"
- when: l2_docker_additional_registries | bool
-- set_fact:
- l_crio_registries: "{{ ['docker.io'] }}"
- when: not (l2_docker_additional_registries | bool)
- set_fact:
l_additional_crio_registries: "{{ '\"{}\"'.format('\", \"'.join(l_crio_registries)) }}"
- when: l2_docker_additional_registries | bool
- set_fact:
l_openshift_image_tag: "{{ openshift_image_tag | string }}"
diff --git a/roles/kuryr/tasks/master.yaml b/roles/kuryr/tasks/master.yaml
index 55ab16f74..1cc6d2375 100644
--- a/roles/kuryr/tasks/master.yaml
+++ b/roles/kuryr/tasks/master.yaml
@@ -1,6 +1,6 @@
---
-- name: Perform OpenShit ServiceAccount config
- include: serviceaccount.yaml
+- name: Perform OpenShift ServiceAccount config
+ include_tasks: serviceaccount.yaml
- name: Create kuryr manifests tempdir
command: mktemp -d
diff --git a/roles/nuage_master/tasks/main.yaml b/roles/nuage_master/tasks/main.yaml
index f3c487132..c264427de 100644
--- a/roles/nuage_master/tasks/main.yaml
+++ b/roles/nuage_master/tasks/main.yaml
@@ -1,7 +1,6 @@
---
- name: setup firewall
- include: firewall.yml
- static: yes
+ import_tasks: firewall.yml
- name: Set the Nuage certificate directory fact for Atomic hosts
set_fact:
@@ -62,7 +61,7 @@
become: yes
file: path={{ nuage_mon_rest_server_logdir }} state=directory
-- include: serviceaccount.yml
+- include_tasks: serviceaccount.yml
- name: Download the certs and keys
become: yes
@@ -82,7 +81,7 @@
- nuage.key
- nuage.kubeconfig
-- include: certificates.yml
+- include_tasks: certificates.yml
- name: Install Nuage VSD user certificate
become: yes
diff --git a/roles/nuage_node/tasks/main.yaml b/roles/nuage_node/tasks/main.yaml
index 9db9dbb6a..c6b7a9b10 100644
--- a/roles/nuage_node/tasks/main.yaml
+++ b/roles/nuage_node/tasks/main.yaml
@@ -31,7 +31,7 @@
- nuage.key
- nuage.kubeconfig
-- include: certificates.yml
+- include_tasks: certificates.yml
- name: Add additional Docker mounts for Nuage for atomic hosts
become: yes
@@ -44,8 +44,7 @@
- restart node
ignore_errors: true
-- include: iptables.yml
+- include_tasks: iptables.yml
- name: setup firewall
- include: firewall.yml
- static: yes
+ import_tasks: firewall.yml
diff --git a/roles/openshift_cloud_provider/tasks/main.yml b/roles/openshift_cloud_provider/tasks/main.yml
index ab3055c8b..dff492a69 100644
--- a/roles/openshift_cloud_provider/tasks/main.yml
+++ b/roles/openshift_cloud_provider/tasks/main.yml
@@ -11,11 +11,11 @@
state: directory
when: has_cloudprovider | bool
-- include: openstack.yml
+- include_tasks: openstack.yml
when: cloudprovider_is_openstack | bool
-- include: aws.yml
+- include_tasks: aws.yml
when: cloudprovider_is_aws | bool
-- include: gce.yml
+- include_tasks: gce.yml
when: cloudprovider_is_gce | bool
diff --git a/roles/openshift_excluder/tasks/disable.yml b/roles/openshift_excluder/tasks/disable.yml
index 5add25b45..21801b994 100644
--- a/roles/openshift_excluder/tasks/disable.yml
+++ b/roles/openshift_excluder/tasks/disable.yml
@@ -2,11 +2,11 @@
- when: r_openshift_excluder_verify_upgrade
block:
- name: Include verify_upgrade.yml when upgrading
- include: verify_upgrade.yml
+ include_tasks: verify_upgrade.yml
# unexclude the current openshift/origin-excluder if it is installed so it can be updated
- name: Disable excluders before the upgrade to remove older excluding expressions
- include: unexclude.yml
+ include_tasks: unexclude.yml
vars:
# before the docker excluder can be updated, it needs to be disabled
# to remove older excluded packages that are no longer excluded
@@ -15,12 +15,12 @@
# Install any excluder that is enabled
- name: Include install.yml
- include: install.yml
+ include_tasks: install.yml
# And finally adjust an excluder in order to update host components correctly. First
# exclude then unexclude
- name: Include exclude.yml
- include: exclude.yml
+ include_tasks: exclude.yml
vars:
# Enable the docker excluder only if it is overridden
# BZ #1430612: docker excluders should be enabled even during installation and upgrade
@@ -30,7 +30,7 @@
# All excluders that are to be disabled are disabled
- name: Include unexclude.yml
- include: unexclude.yml
+ include_tasks: unexclude.yml
vars:
# If the docker override is not set, default to the generic behaviour
# BZ #1430612: docker excluders should be enabled even during installation and upgrade
diff --git a/roles/openshift_excluder/tasks/enable.yml b/roles/openshift_excluder/tasks/enable.yml
index fce44cfb5..7c3742a06 100644
--- a/roles/openshift_excluder/tasks/enable.yml
+++ b/roles/openshift_excluder/tasks/enable.yml
@@ -1,6 +1,6 @@
---
- name: Install excluders
- include: install.yml
+ include_tasks: install.yml
- name: Enable excluders
- include: exclude.yml
+ include_tasks: exclude.yml
diff --git a/roles/openshift_excluder/tasks/main.yml b/roles/openshift_excluder/tasks/main.yml
index db20b4012..93d6ef149 100644
--- a/roles/openshift_excluder/tasks/main.yml
+++ b/roles/openshift_excluder/tasks/main.yml
@@ -32,7 +32,7 @@
- r_openshift_excluder_upgrade_target is not defined
- name: Include main action task file
- include: "{{ r_openshift_excluder_action }}.yml"
+ include_tasks: "{{ r_openshift_excluder_action }}.yml"
when:
- not ostree_booted.stat.exists | bool
diff --git a/roles/openshift_excluder/tasks/verify_upgrade.yml b/roles/openshift_excluder/tasks/verify_upgrade.yml
index 42026664a..b55a9af23 100644
--- a/roles/openshift_excluder/tasks/verify_upgrade.yml
+++ b/roles/openshift_excluder/tasks/verify_upgrade.yml
@@ -1,12 +1,12 @@
---
- name: Verify Docker Excluder version
- include: verify_excluder.yml
+ include_tasks: verify_excluder.yml
vars:
excluder: "{{ r_openshift_excluder_service_type }}-docker-excluder"
when: r_openshift_excluder_enable_docker_excluder | bool
- name: Verify OpenShift Excluder version
- include: verify_excluder.yml
+ include_tasks: verify_excluder.yml
vars:
excluder: "{{ r_openshift_excluder_service_type }}-excluder"
when: r_openshift_excluder_enable_openshift_excluder | bool
diff --git a/roles/openshift_master/defaults/main.yml b/roles/openshift_master/defaults/main.yml
index 99bc12514..e9a51e55b 100644
--- a/roles/openshift_master/defaults/main.yml
+++ b/roles/openshift_master/defaults/main.yml
@@ -13,6 +13,8 @@ system_images_registry_dict:
system_images_registry: "{{ system_images_registry_dict[openshift_deployment_type | default('origin')] }}"
+l_is_master_system_container: "{{ (openshift_use_master_system_container | default(openshift_use_system_containers | default(false)) | bool) }}"
+
openshift_node_ips: []
r_openshift_master_clean_install: false
r_openshift_master_etcd3_storage: false
diff --git a/roles/openshift_master/tasks/main.yml b/roles/openshift_master/tasks/main.yml
index b6d3539b1..d570a1c7f 100644
--- a/roles/openshift_master/tasks/main.yml
+++ b/roles/openshift_master/tasks/main.yml
@@ -31,8 +31,7 @@
- openshift.common.is_containerized | bool
- name: Open up firewall ports
- include: firewall.yml
- static: yes
+ import_tasks: firewall.yml
- name: Install Master package
package:
@@ -172,16 +171,16 @@
no_proxy_etcd_host_ips: "{{ openshift_no_proxy_etcd_host_ips }}"
- name: Update journald config
- include: journald.yml
+ include_tasks: journald.yml
- name: Install the systemd units
- include: systemd_units.yml
+ include_tasks: systemd_units.yml
- name: Install Master system container
- include: system_container.yml
+ include_tasks: system_container.yml
when:
- openshift.common.is_containerized | bool
- - openshift.common.is_master_system_container | bool
+ - l_is_master_system_container | bool
- name: Create session secrets file
template:
@@ -212,10 +211,10 @@
- restart master api
- restart master controllers
-- include: bootstrap_settings.yml
+- include_tasks: bootstrap_settings.yml
when: openshift_master_bootstrap_enabled | default(False)
-- include: set_loopback_context.yml
+- include_tasks: set_loopback_context.yml
- name: Start and enable master api on first master
systemd:
@@ -273,7 +272,7 @@
# A separate wait is required here for native HA since notifies will
# be resolved after all tasks in the role.
-- include: check_master_api_is_ready.yml
+- include_tasks: check_master_api_is_ready.yml
when:
- openshift.master.cluster_method == 'native'
- master_api_service_status_changed | bool
@@ -323,5 +322,5 @@
- l_install_result | changed
- name: node bootstrap settings
- include: bootstrap.yml
+ include_tasks: bootstrap.yml
when: openshift_master_bootstrap_enabled | default(False)
diff --git a/roles/openshift_master/tasks/systemd_units.yml b/roles/openshift_master/tasks/systemd_units.yml
index b0fa72f19..9d11ed574 100644
--- a/roles/openshift_master/tasks/systemd_units.yml
+++ b/roles/openshift_master/tasks/systemd_units.yml
@@ -9,7 +9,7 @@
when:
- openshift.common.is_containerized | bool
-- include: registry_auth.yml
+- include_tasks: registry_auth.yml
- name: Disable the legacy master service if it exists
systemd:
@@ -26,7 +26,7 @@
ignore_errors: true
when:
- openshift.master.cluster_method == "native"
- - not openshift.common.is_master_system_container | bool
+ - not l_is_master_system_container | bool
# This is the image used for both HA and non-HA clusters:
- name: Pre-pull master image
@@ -36,7 +36,7 @@
changed_when: "'Downloaded newer image' in l_pull_result.stdout"
when:
- openshift.common.is_containerized | bool
- - not openshift.common.is_master_system_container | bool
+ - not l_is_master_system_container | bool
- name: Create the ha systemd unit files
template:
@@ -44,7 +44,7 @@
dest: "{{ containerized_svc_dir }}/{{ openshift.common.service_type }}-master-{{ item }}.service"
when:
- openshift.master.cluster_method == "native"
- - not openshift.common.is_master_system_container | bool
+ - not l_is_master_system_container | bool
with_items:
- api
- controllers
@@ -64,7 +64,7 @@
- controllers
when:
- openshift.master.cluster_method == "native"
- - not openshift.common.is_master_system_container | bool
+ - not l_is_master_system_container | bool
- name: Preserve Master API Proxy Config options
command: grep PROXY /etc/sysconfig/{{ openshift.common.service_type }}-master-api
diff --git a/roles/openshift_master/tasks/upgrade.yml b/roles/openshift_master/tasks/upgrade.yml
index 92371921d..f84cf2f6e 100644
--- a/roles/openshift_master/tasks/upgrade.yml
+++ b/roles/openshift_master/tasks/upgrade.yml
@@ -1,16 +1,16 @@
---
-- include: upgrade/rpm_upgrade.yml
+- include_tasks: upgrade/rpm_upgrade.yml
when: not openshift.common.is_containerized | bool
-- include: upgrade/upgrade_scheduler.yml
+- include_tasks: upgrade/upgrade_scheduler.yml
# master_config_hook is passed in from upgrade play.
-- include: "upgrade/{{ master_config_hook }}"
+- include_tasks: "upgrade/{{ master_config_hook }}"
when: master_config_hook is defined
-- include: journald.yml
+- include_tasks: journald.yml
-- include: systemd_units.yml
+- include_tasks: systemd_units.yml
- name: Check for ca-bundle.crt
stat:
diff --git a/roles/openshift_master_cluster/tasks/main.yml b/roles/openshift_master_cluster/tasks/main.yml
index 40705d357..41bfc72cb 100644
--- a/roles/openshift_master_cluster/tasks/main.yml
+++ b/roles/openshift_master_cluster/tasks/main.yml
@@ -10,5 +10,5 @@
failed_when: false
when: openshift.master.cluster_method == "pacemaker"
-- include: configure.yml
+- include_tasks: configure.yml
when: "pcs_status | failed and 'Error: cluster is not currently running on this node' in pcs_status.stderr"
diff --git a/roles/openshift_node/defaults/main.yml b/roles/openshift_node/defaults/main.yml
index d249278dc..62208c155 100644
--- a/roles/openshift_node/defaults/main.yml
+++ b/roles/openshift_node/defaults/main.yml
@@ -14,6 +14,7 @@ system_images_registry_dict:
origin: "docker.io"
system_images_registry: "{{ system_images_registry_dict[openshift_deployment_type | default('origin')] }}"
+l_is_openvswitch_system_container: "{{ (openshift_use_openvswitch_system_container | default(openshift_use_system_containers | default(false)) | bool) }}"
openshift_image_tag: ''
diff --git a/roles/openshift_node/tasks/bootstrap.yml b/roles/openshift_node/tasks/bootstrap.yml
index b8be50f6c..ac43ef039 100644
--- a/roles/openshift_node/tasks/bootstrap.yml
+++ b/roles/openshift_node/tasks/bootstrap.yml
@@ -32,8 +32,7 @@
regexp: "^CONFIG_FILE=.*"
- name: include aws sysconfig credentials
- include: aws.yml
- static: yes
+ import_tasks: aws.yml
when: not (openshift_node_use_instance_profiles | default(False))
#- name: update the ExecStart to have bootstrap
diff --git a/roles/openshift_node/tasks/config.yml b/roles/openshift_node/tasks/config.yml
index 2fea33454..741a2234f 100644
--- a/roles/openshift_node/tasks/config.yml
+++ b/roles/openshift_node/tasks/config.yml
@@ -1,6 +1,6 @@
---
- name: Install the systemd units
- include: systemd_units.yml
+ include_tasks: systemd_units.yml
- name: Start and enable openvswitch service
systemd:
@@ -47,8 +47,7 @@
- restart node
- name: include aws provider credentials
- include: aws.yml
- static: yes
+ import_tasks: aws.yml
when: not (openshift_node_use_instance_profiles | default(False))
# Necessary because when you're on a node that's also a master the master will be
diff --git a/roles/openshift_node/tasks/main.yml b/roles/openshift_node/tasks/main.yml
index eae9ca7bc..8e9d1d1b5 100644
--- a/roles/openshift_node/tasks/main.yml
+++ b/roles/openshift_node/tasks/main.yml
@@ -7,8 +7,7 @@
- not openshift_use_crio | default(false)
- name: setup firewall
- include: firewall.yml
- static: yes
+ import_tasks: firewall.yml
#### Disable SWAP #####
# https://docs.openshift.com/container-platform/3.4/admin_guide/overcommit.html#disabling-swap-memory
@@ -41,7 +40,7 @@
#### End Disable Swap Block ####
- name: include node installer
- include: install.yml
+ include_tasks: install.yml
- name: Restart cri-o
systemd:
@@ -66,34 +65,34 @@
sysctl_file: "/etc/sysctl.d/99-openshift.conf"
reload: yes
-- include: registry_auth.yml
+- include_tasks: registry_auth.yml
- name: include standard node config
- include: config.yml
+ include_tasks: config.yml
#### Storage class plugins here ####
- name: NFS storage plugin configuration
- include: storage_plugins/nfs.yml
+ include_tasks: storage_plugins/nfs.yml
tags:
- nfs
- name: GlusterFS storage plugin configuration
- include: storage_plugins/glusterfs.yml
+ include_tasks: storage_plugins/glusterfs.yml
when: "'glusterfs' in openshift.node.storage_plugin_deps"
- name: Ceph storage plugin configuration
- include: storage_plugins/ceph.yml
+ include_tasks: storage_plugins/ceph.yml
when: "'ceph' in openshift.node.storage_plugin_deps"
- name: iSCSI storage plugin configuration
- include: storage_plugins/iscsi.yml
+ include_tasks: storage_plugins/iscsi.yml
when: "'iscsi' in openshift.node.storage_plugin_deps"
##### END Storage #####
-- include: config/workaround-bz1331590-ovs-oom-fix.yml
+- include_tasks: config/workaround-bz1331590-ovs-oom-fix.yml
when: openshift_node_use_openshift_sdn | default(true) | bool
- name: include bootstrap node config
- include: bootstrap.yml
+ include_tasks: bootstrap.yml
when: openshift_node_bootstrap
diff --git a/roles/openshift_node/tasks/systemd_units.yml b/roles/openshift_node/tasks/systemd_units.yml
index 9b4c24dfe..397e1ba18 100644
--- a/roles/openshift_node/tasks/systemd_units.yml
+++ b/roles/openshift_node/tasks/systemd_units.yml
@@ -11,21 +11,21 @@
- when: openshift.common.is_containerized | bool
block:
- name: include node deps docker service file
- include: config/install-node-deps-docker-service-file.yml
+ include_tasks: config/install-node-deps-docker-service-file.yml
- name: include ovs service environment file
- include: config/install-ovs-service-env-file.yml
+ include_tasks: config/install-ovs-service-env-file.yml
- name: Install Node system container
- include: node_system_container.yml
+ include_tasks: node_system_container.yml
when:
- l_is_node_system_container | bool
- name: Install OpenvSwitch system containers
- include: openvswitch_system_container.yml
+ include_tasks: openvswitch_system_container.yml
when:
- openshift_node_use_openshift_sdn | bool
- - openshift.common.is_openvswitch_system_container | bool
+ - l_is_openvswitch_system_container | bool
- block:
- name: Pre-pull openvswitch image
@@ -34,11 +34,11 @@
register: pull_result
changed_when: "'Downloaded newer image' in pull_result.stdout"
- - include: config/install-ovs-docker-service-file.yml
+ - include_tasks: config/install-ovs-docker-service-file.yml
when:
- openshift.common.is_containerized | bool
- openshift_node_use_openshift_sdn | bool
- - not openshift.common.is_openvswitch_system_container | bool
+ - not l_is_openvswitch_system_container | bool
-- include: config/configure-node-settings.yml
-- include: config/configure-proxy-settings.yml
+- include_tasks: config/configure-node-settings.yml
+- include_tasks: config/configure-proxy-settings.yml
diff --git a/roles/openshift_node/tasks/upgrade.yml b/roles/openshift_node/tasks/upgrade.yml
index 2bca1e974..fb21b39a1 100644
--- a/roles/openshift_node/tasks/upgrade.yml
+++ b/roles/openshift_node/tasks/upgrade.yml
@@ -10,7 +10,7 @@
# tasks file for openshift_node_upgrade
-- include: registry_auth.yml
+- include_tasks: registry_auth.yml
- name: Stop node and openvswitch services
service:
@@ -48,7 +48,7 @@
- openshift.common.is_containerized | bool
- openshift_use_openshift_sdn | bool
-- include: docker/upgrade.yml
+- include_tasks: docker/upgrade.yml
vars:
# We will restart Docker ourselves after everything is ready:
skip_docker_restart: True
@@ -56,10 +56,10 @@
- l_docker_upgrade is defined
- l_docker_upgrade | bool
-- include: "{{ node_config_hook }}"
+- include_tasks: "{{ node_config_hook }}"
when: node_config_hook is defined
-- include: upgrade/rpm_upgrade.yml
+- include_tasks: upgrade/rpm_upgrade.yml
vars:
component: "node"
openshift_version: "{{ openshift_pkg_version | default('') }}"
@@ -70,7 +70,7 @@
path: "/etc/systemd/system/docker.service.d/docker-sdn-ovs.conf"
state: absent
-- include: upgrade/containerized_node_upgrade.yml
+- include_tasks: upgrade/containerized_node_upgrade.yml
when: openshift.common.is_containerized | bool
- name: Ensure containerized services stopped before Docker restart
@@ -165,7 +165,7 @@
value: "/etc/origin/node/resolv.conf"
# Restart all services
-- include: upgrade/restart.yml
+- include_tasks: upgrade/restart.yml
- name: Wait for node to be ready
oc_obj:
diff --git a/roles/openshift_node/tasks/upgrade/containerized_node_upgrade.yml b/roles/openshift_node/tasks/upgrade/containerized_node_upgrade.yml
index 96b94d8b6..245de60a7 100644
--- a/roles/openshift_node/tasks/upgrade/containerized_node_upgrade.yml
+++ b/roles/openshift_node/tasks/upgrade/containerized_node_upgrade.yml
@@ -6,7 +6,7 @@
skip_node_svc_handlers: True
- name: Update systemd units
- include: ../systemd_units.yml
+ include_tasks: ../systemd_units.yml
# This is a no-op because of skip_node_svc_handlers, but lets us trigger it before end of
# play when the node has already been marked schedulable again. (this would look strange
diff --git a/roles/openshift_node_dnsmasq/tasks/main.yml b/roles/openshift_node_dnsmasq/tasks/main.yml
index 9bbaafc29..a33b78780 100644
--- a/roles/openshift_node_dnsmasq/tasks/main.yml
+++ b/roles/openshift_node_dnsmasq/tasks/main.yml
@@ -59,9 +59,9 @@
state: started
# Dynamic NetworkManager based dispatcher
-- include: ./network-manager.yml
+- include_tasks: ./network-manager.yml
when: network_manager_active | bool
# Relies on ansible in order to configure static config
-- include: ./no-network-manager.yml
+- include_tasks: ./no-network-manager.yml
when: not network_manager_active | bool
diff --git a/roles/openshift_node_dnsmasq/tasks/no-network-manager.yml b/roles/openshift_node_dnsmasq/tasks/no-network-manager.yml
index 8a7da66c2..dede2fb8f 100644
--- a/roles/openshift_node_dnsmasq/tasks/no-network-manager.yml
+++ b/roles/openshift_node_dnsmasq/tasks/no-network-manager.yml
@@ -8,4 +8,4 @@
state: present
notify: restart NetworkManager
-- include: ./network-manager.yml
+- include_tasks: network-manager.yml
diff --git a/roles/openshift_node_group/tasks/main.yml b/roles/openshift_node_group/tasks/main.yml
index c7c15683d..43ecf1b8b 100644
--- a/roles/openshift_node_group/tasks/main.yml
+++ b/roles/openshift_node_group/tasks/main.yml
@@ -1,6 +1,6 @@
---
- name: Build node config maps
- include: create_config.yml
+ include_tasks: create_config.yml
vars:
openshift_node_group_name: "{{ node_group.name }}"
openshift_node_group_edits: "{{ node_group.edits | default([]) }}"
diff --git a/roles/openshift_prometheus/README.md b/roles/openshift_prometheus/README.md
index 5bf6e7d77..f1eca1da6 100644
--- a/roles/openshift_prometheus/README.md
+++ b/roles/openshift_prometheus/README.md
@@ -25,6 +25,10 @@ For default values, see [`defaults/main.yaml`](defaults/main.yaml).
- `openshift_prometheus_args`: Modify or add arguments for prometheus application
+- `openshift_prometheus_hostname`: specify the hostname for the route to prometheus `prometheus-{{openshift_prometheus_namespace}}.{{openshift_master_default_subdomain}}`
+
+- `openshift_prometheus_alerts_hostname`: specify the hostname for the route to prometheus-alerts `prometheus_alerts-{{openshift_prometheus_namespace}}.{{openshift_master_default_subdomain}}`
+
e.g
```
openshift_prometheus_args=['--storage.tsdb.retention=6h', '--storage.tsdb.min-block-duration=5s', '--storage.tsdb.max-block-duration=6m']
diff --git a/roles/openshift_prometheus/defaults/main.yaml b/roles/openshift_prometheus/defaults/main.yaml
index 1b4a12cac..df331a4bb 100644
--- a/roles/openshift_prometheus/defaults/main.yaml
+++ b/roles/openshift_prometheus/defaults/main.yaml
@@ -4,6 +4,10 @@ openshift_prometheus_state: present
openshift_prometheus_namespace: openshift-metrics
+# defaults hosts for routes
+openshift_prometheus_hostname: prometheus-{{openshift_prometheus_namespace}}.{{openshift_master_default_subdomain}}
+openshift_prometheus_alerts_hostname: alerts-{{openshift_prometheus_namespace}}.{{openshift_master_default_subdomain}}
+
openshift_prometheus_node_selector: {"region":"infra"}
# additional prometheus rules file
diff --git a/roles/openshift_prometheus/tasks/install_prometheus.yaml b/roles/openshift_prometheus/tasks/install_prometheus.yaml
index 50736a9ee..ad15dc65f 100644
--- a/roles/openshift_prometheus/tasks/install_prometheus.yaml
+++ b/roles/openshift_prometheus/tasks/install_prometheus.yaml
@@ -113,12 +113,15 @@
oc_route:
state: present
name: "{{ item.name }}"
+ host: "{{ item.host }}"
namespace: "{{ openshift_prometheus_namespace }}"
service_name: "{{ item.name }}"
tls_termination: reencrypt
with_items:
- name: prometheus
+ host: "{{ openshift_prometheus_hostname }}"
- name: alerts
+ host: "{{ openshift_prometheus_alerts_hostname }}"
# Storage
- name: create prometheus pvc
diff --git a/roles/openshift_storage_glusterfs/files/v3.7/glusterblock-provisioner.yml b/roles/openshift_storage_glusterfs/files/v3.7/glusterblock-provisioner.yml
index 9c1409dee..63dd5cce6 100644
--- a/roles/openshift_storage_glusterfs/files/v3.7/glusterblock-provisioner.yml
+++ b/roles/openshift_storage_glusterfs/files/v3.7/glusterblock-provisioner.yml
@@ -83,7 +83,6 @@ objects:
containers:
- name: glusterblock-provisioner
image: ${IMAGE_NAME}:${IMAGE_VERSION}
- image: gluster/glusterblock-provisioner:latest
imagePullPolicy: IfNotPresent
env:
- name: PROVISIONER_NAME
diff --git a/roles/openshift_storage_glusterfs/files/v3.8/glusterblock-provisioner.yml b/roles/openshift_storage_glusterfs/files/v3.8/glusterblock-provisioner.yml
index 9c1409dee..63dd5cce6 100644
--- a/roles/openshift_storage_glusterfs/files/v3.8/glusterblock-provisioner.yml
+++ b/roles/openshift_storage_glusterfs/files/v3.8/glusterblock-provisioner.yml
@@ -83,7 +83,6 @@ objects:
containers:
- name: glusterblock-provisioner
image: ${IMAGE_NAME}:${IMAGE_VERSION}
- image: gluster/glusterblock-provisioner:latest
imagePullPolicy: IfNotPresent
env:
- name: PROVISIONER_NAME
diff --git a/tox.ini b/tox.ini
index 899767833..46738cae5 100644
--- a/tox.ini
+++ b/tox.ini
@@ -12,11 +12,11 @@ skip_install=True
deps =
-rrequirements.txt
-rtest-requirements.txt
+ unit: -eutils
py35-flake8: flake8-bugbear==17.3.0
integration: docker-py==1.10.6
commands =
- unit: pip install -e utils
unit: pytest {posargs}
flake8: flake8 {posargs}
pylint: python setup.py lint