From 88a2b2de8c3b5d79173effca87fed73141e07abb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Han?= Date: Wed, 1 Feb 2017 17:18:17 +0100 Subject: [PATCH] docker: fail if systemd is not present MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since we treat containers as services using systemd, systemd is an absolute requirement. Signed-off-by: Sébastien Han --- roles/ceph-docker-common/tasks/main.yml | 2 ++ roles/ceph-docker-common/tasks/system_checks.yml | 5 +++++ 2 files changed, 7 insertions(+) create mode 100644 roles/ceph-docker-common/tasks/main.yml create mode 100644 roles/ceph-docker-common/tasks/system_checks.yml diff --git a/roles/ceph-docker-common/tasks/main.yml b/roles/ceph-docker-common/tasks/main.yml new file mode 100644 index 000000000..14e987cde --- /dev/null +++ b/roles/ceph-docker-common/tasks/main.yml @@ -0,0 +1,2 @@ +--- +- include: system_checks.yml diff --git a/roles/ceph-docker-common/tasks/system_checks.yml b/roles/ceph-docker-common/tasks/system_checks.yml new file mode 100644 index 000000000..a9a5311e6 --- /dev/null +++ b/roles/ceph-docker-common/tasks/system_checks.yml @@ -0,0 +1,5 @@ +--- +- name: fail if systemd is not present + fail: + msg: "Systemd must be present" + when: ansible_service_mgr != 'systemd'