summaryrefslogtreecommitdiffstats
path: root/docker/ansible/roles/config_files/tasks/mcelog.yml
diff options
context:
space:
mode:
authorKamil Wiatrowski <kamilx.wiatrowski@intel.com>2018-06-07 05:13:01 +0100
committerKamil Wiatrowski <kamilx.wiatrowski@intel.com>2018-09-28 16:47:42 +0200
commit24c5124e304b8e2854d98284f6ee4715a75ee735 (patch)
tree420ff7e0158e3a8c68d3e2710469fbcb9c06c853 /docker/ansible/roles/config_files/tasks/mcelog.yml
parentb52c942a4fbfc5023780d23954de953b817c6dc0 (diff)
WIP: Add role to auto install docker on hosts
Auto install docker with dependencies on hosts: apt install python apt install python-pip pip install docker-py apt install docker.io Set docker proxy using host proxy settings. Updated documentation. Change-Id: Ibec7e0a7e484d5a9a8656cd3598c3acc7c2e2184 Signed-off-by: Kamil Wiatrowski <kamilx.wiatrowski@intel.com>
Diffstat (limited to 'docker/ansible/roles/config_files/tasks/mcelog.yml')
-rw-r--r--docker/ansible/roles/config_files/tasks/mcelog.yml17
1 files changed, 17 insertions, 0 deletions
diff --git a/docker/ansible/roles/config_files/tasks/mcelog.yml b/docker/ansible/roles/config_files/tasks/mcelog.yml
index 9c935e3e..bab4b142 100644
--- a/docker/ansible/roles/config_files/tasks/mcelog.yml
+++ b/docker/ansible/roles/config_files/tasks/mcelog.yml
@@ -13,6 +13,23 @@
# limitations under the License.
---
+- name: install mcelog package
+ package:
+ name: mcelog
+ state: present
+ when: install_mcelog|default(false)|bool
+ tags:
+ - mcelogs
+
+- name: start mcelog daemon if not running
+ service:
+ name: mcelog
+ state: started
+ enabled: true
+ when: install_mcelog|default(false)|bool
+ tags:
+ - mcelogs
+
- name: check if mcelog running on host
shell: ps -ef | grep mcelog | grep -v grep > /dev/null
register: mcelog_running