From 2f76a594258e3ccdf55101c7266c65bd99c59abc Mon Sep 17 00:00:00 2001 From: Russell Teague Date: Thu, 16 Nov 2017 15:53:54 -0500 Subject: Playbook Consolidation - openshift-logging --- playbooks/aws/openshift-cluster/hosted.yml | 2 +- .../byo/openshift-cluster/openshift-logging.yml | 10 ++---- playbooks/common/openshift-cluster/config.yml | 2 +- .../common/openshift-cluster/openshift_logging.yml | 37 ---------------------- playbooks/openshift-logging/config.yml | 9 ++++++ playbooks/openshift-logging/private/config.yml | 37 ++++++++++++++++++++++ playbooks/openshift-logging/private/library | 1 + playbooks/openshift-logging/private/roles | 1 + .../callback_plugins/installer_checkpoint.py | 2 +- 9 files changed, 53 insertions(+), 48 deletions(-) delete mode 100644 playbooks/common/openshift-cluster/openshift_logging.yml create mode 100644 playbooks/openshift-logging/config.yml create mode 100644 playbooks/openshift-logging/private/config.yml create mode 120000 playbooks/openshift-logging/private/library create mode 120000 playbooks/openshift-logging/private/roles diff --git a/playbooks/aws/openshift-cluster/hosted.yml b/playbooks/aws/openshift-cluster/hosted.yml index da7ec9d21..1dabae357 100644 --- a/playbooks/aws/openshift-cluster/hosted.yml +++ b/playbooks/aws/openshift-cluster/hosted.yml @@ -4,7 +4,7 @@ - include: ../../openshift-metrics/private/config.yml when: openshift_metrics_install_metrics | default(false) | bool -- include: ../../common/openshift-cluster/openshift_logging.yml +- include: ../../openshift-logging/private/config.yml when: openshift_logging_install_logging | default(false) | bool - include: ../../openshift-prometheus/private/config.yml diff --git a/playbooks/byo/openshift-cluster/openshift-logging.yml b/playbooks/byo/openshift-cluster/openshift-logging.yml index 74e186f33..76bd47c4f 100644 --- a/playbooks/byo/openshift-cluster/openshift-logging.yml +++ b/playbooks/byo/openshift-cluster/openshift-logging.yml @@ -1,9 +1,3 @@ --- -# -# This playbook is a preview of upcoming changes for installing -# Hosted logging on. See inventory/byo/hosts.*.example for the -# currently supported method. -# -- include: ../../init/main.yml - -- include: ../../common/openshift-cluster/openshift_logging.yml +# TODO (rteague): Temporarily leaving this playbook to allow CI tests to operate until CI jobs are updated. +- include: ../../openshift-logging/config.yml diff --git a/playbooks/common/openshift-cluster/config.yml b/playbooks/common/openshift-cluster/config.yml index 2eeb81b86..a8ca5e686 100644 --- a/playbooks/common/openshift-cluster/config.yml +++ b/playbooks/common/openshift-cluster/config.yml @@ -23,7 +23,7 @@ - include: ../../openshift-metrics/private/config.yml when: openshift_metrics_install_metrics | default(false) | bool -- include: openshift_logging.yml +- include: ../../openshift-logging/private/config.yml when: openshift_logging_install_logging | default(false) | bool - include: ../../openshift-prometheus/private/config.yml diff --git a/playbooks/common/openshift-cluster/openshift_logging.yml b/playbooks/common/openshift-cluster/openshift_logging.yml deleted file mode 100644 index bc59bd95a..000000000 --- a/playbooks/common/openshift-cluster/openshift_logging.yml +++ /dev/null @@ -1,37 +0,0 @@ ---- -- name: Logging Install Checkpoint Start - hosts: all - gather_facts: false - tasks: - - name: Set Logging install 'In Progress' - run_once: true - set_stats: - data: - installer_phase_logging: - status: "In Progress" - start: "{{ lookup('pipe', 'date +%Y%m%d%H%M%SZ') }}" - -- name: OpenShift Aggregated Logging - hosts: oo_first_master - roles: - - openshift_logging - -- name: Update Master configs - hosts: oo_masters:!oo_first_master - tasks: - - block: - - include_role: - name: openshift_logging - tasks_from: update_master_config - -- name: Logging Install Checkpoint End - hosts: all - gather_facts: false - tasks: - - name: Set Logging install 'Complete' - run_once: true - set_stats: - data: - installer_phase_logging: - status: "Complete" - end: "{{ lookup('pipe', 'date +%Y%m%d%H%M%SZ') }}" diff --git a/playbooks/openshift-logging/config.yml b/playbooks/openshift-logging/config.yml new file mode 100644 index 000000000..8837a2d32 --- /dev/null +++ b/playbooks/openshift-logging/config.yml @@ -0,0 +1,9 @@ +--- +# +# This playbook is a preview of upcoming changes for installing +# Hosted logging on. See inventory/byo/hosts.*.example for the +# currently supported method. +# +- include: ../init/main.yml + +- include: private/config.yml diff --git a/playbooks/openshift-logging/private/config.yml b/playbooks/openshift-logging/private/config.yml new file mode 100644 index 000000000..bc59bd95a --- /dev/null +++ b/playbooks/openshift-logging/private/config.yml @@ -0,0 +1,37 @@ +--- +- name: Logging Install Checkpoint Start + hosts: all + gather_facts: false + tasks: + - name: Set Logging install 'In Progress' + run_once: true + set_stats: + data: + installer_phase_logging: + status: "In Progress" + start: "{{ lookup('pipe', 'date +%Y%m%d%H%M%SZ') }}" + +- name: OpenShift Aggregated Logging + hosts: oo_first_master + roles: + - openshift_logging + +- name: Update Master configs + hosts: oo_masters:!oo_first_master + tasks: + - block: + - include_role: + name: openshift_logging + tasks_from: update_master_config + +- name: Logging Install Checkpoint End + hosts: all + gather_facts: false + tasks: + - name: Set Logging install 'Complete' + run_once: true + set_stats: + data: + installer_phase_logging: + status: "Complete" + end: "{{ lookup('pipe', 'date +%Y%m%d%H%M%SZ') }}" diff --git a/playbooks/openshift-logging/private/library b/playbooks/openshift-logging/private/library new file mode 120000 index 000000000..ba40d2f56 --- /dev/null +++ b/playbooks/openshift-logging/private/library @@ -0,0 +1 @@ +../../../library \ No newline at end of file diff --git a/playbooks/openshift-logging/private/roles b/playbooks/openshift-logging/private/roles new file mode 120000 index 000000000..20c4c58cf --- /dev/null +++ b/playbooks/openshift-logging/private/roles @@ -0,0 +1 @@ +../../../roles \ No newline at end of file diff --git a/roles/installer_checkpoint/callback_plugins/installer_checkpoint.py b/roles/installer_checkpoint/callback_plugins/installer_checkpoint.py index 57444a2a5..f10dcc11b 100644 --- a/roles/installer_checkpoint/callback_plugins/installer_checkpoint.py +++ b/roles/installer_checkpoint/callback_plugins/installer_checkpoint.py @@ -86,7 +86,7 @@ class CallbackModule(CallbackBase): }, 'installer_phase_logging': { 'title': 'Logging Install', - 'playbook': 'playbooks/byo/openshift-cluster/openshift-logging.yml' + 'playbook': 'playbooks/openshift-logging/config.yml' }, 'installer_phase_prometheus': { 'title': 'Prometheus Install', -- cgit v1.2.1