summaryrefslogtreecommitdiffstats
path: root/roles/openshift_metrics
diff options
context:
space:
mode:
authorRussell Teague <rteague@redhat.com>2016-11-18 14:26:02 -0500
committerRussell Teague <rteague@redhat.com>2016-11-28 11:11:44 -0500
commitec9c22ca6a376b7d1139a384dcb78f3f5bb5b607 (patch)
treea8c3897b9765b9b6dc02582a851b704be8f0828e /roles/openshift_metrics
parentb45db4c7e0b278623f7531cee50127aa24686139 (diff)
downloadopenshift-ec9c22ca6a376b7d1139a384dcb78f3f5bb5b607.tar.gz
openshift-ec9c22ca6a376b7d1139a384dcb78f3f5bb5b607.tar.bz2
openshift-ec9c22ca6a376b7d1139a384dcb78f3f5bb5b607.tar.xz
openshift-ec9c22ca6a376b7d1139a384dcb78f3f5bb5b607.zip
Refactored to use Ansible systemd module
* Ansible systemd module used in place of service module * Refactored command tasks which are no longer necessary * Applying rules from openshift-ansible Best Practices Guide
Diffstat (limited to 'roles/openshift_metrics')
-rw-r--r--roles/openshift_metrics/README.md6
-rw-r--r--roles/openshift_metrics/handlers/main.yml6
-rw-r--r--roles/openshift_metrics/meta/main.yaml16
3 files changed, 22 insertions, 6 deletions
diff --git a/roles/openshift_metrics/README.md b/roles/openshift_metrics/README.md
index 30a0a608d..f3c0f3474 100644
--- a/roles/openshift_metrics/README.md
+++ b/roles/openshift_metrics/README.md
@@ -5,8 +5,10 @@ OpenShift Metrics Installation
Requirements
------------
-It requires subdomain fqdn to be set.
-If persistence is enabled, then it also requires NFS.
+
+* Ansible 2.2
+* It requires subdomain fqdn to be set.
+* If persistence is enabled, then it also requires NFS.
Role Variables
--------------
diff --git a/roles/openshift_metrics/handlers/main.yml b/roles/openshift_metrics/handlers/main.yml
index e119db1a2..69c5a1663 100644
--- a/roles/openshift_metrics/handlers/main.yml
+++ b/roles/openshift_metrics/handlers/main.yml
@@ -1,16 +1,16 @@
---
- name: restart master
- service: name={{ openshift.common.service_type }}-master state=restarted
+ systemd: name={{ openshift.common.service_type }}-master state=restarted
when: (openshift.master.ha is not defined or not openshift.master.ha | bool) and (not (master_service_status_changed | default(false) | bool))
notify: Verify API Server
- name: restart master api
- service: name={{ openshift.common.service_type }}-master-api state=restarted
+ systemd: name={{ openshift.common.service_type }}-master-api state=restarted
when: (openshift.master.ha is defined and openshift.master.ha | bool) and (not (master_api_service_status_changed | default(false) | bool)) and openshift.master.cluster_method == 'native'
notify: Verify API Server
- name: restart master controllers
- service: name={{ openshift.common.service_type }}-master-controllers state=restarted
+ systemd: name={{ openshift.common.service_type }}-master-controllers state=restarted
when: (openshift.master.ha is defined and openshift.master.ha | bool) and (not (master_controllers_service_status_changed | default(false) | bool)) and openshift.master.cluster_method == 'native'
- name: Verify API Server
diff --git a/roles/openshift_metrics/meta/main.yaml b/roles/openshift_metrics/meta/main.yaml
index 5f8d4f5c5..a89467de5 100644
--- a/roles/openshift_metrics/meta/main.yaml
+++ b/roles/openshift_metrics/meta/main.yaml
@@ -1,3 +1,17 @@
+---
+galaxy_info:
+ author: David Martín
+ description:
+ company:
+ license: Apache License, Version 2.0
+ min_ansible_version: 2.2
+ platforms:
+ - name: EL
+ versions:
+ - 7
+ categories:
+ - cloud
+ - system
dependencies:
- { role: openshift_examples }
-- { role: openshift_facts } \ No newline at end of file
+- { role: openshift_facts }