From: Guillaume Abrioux Date: Fri, 19 Oct 2018 13:57:18 +0000 (+0200) Subject: docker-common: remove legacy tasks for ntp configuration X-Git-Tag: v4.0.0beta1~230 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=cd0195c5622ecc2d0001eb7c988d7b6a6fac1d5e;p=ceph-ansible.git docker-common: remove legacy tasks for ntp configuration Those tasks aren't needed in docker-common since the introduction of `ceph-infra` role. They are duplicated tasks. Signed-off-by: Guillaume Abrioux --- diff --git a/roles/ceph-docker-common/tasks/checks/check_ntp_atomic.yml b/roles/ceph-docker-common/tasks/checks/check_ntp_atomic.yml deleted file mode 100644 index 668655bc2..000000000 --- a/roles/ceph-docker-common/tasks/checks/check_ntp_atomic.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -- name: check ntp installation on atomic - command: rpm -q chrony - args: - warn: no - register: ntp_pkg_query - ignore_errors: true - check_mode: no - changed_when: false diff --git a/roles/ceph-docker-common/tasks/checks/check_ntp_debian.yml b/roles/ceph-docker-common/tasks/checks/check_ntp_debian.yml deleted file mode 100644 index 6cdc07d9b..000000000 --- a/roles/ceph-docker-common/tasks/checks/check_ntp_debian.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -- name: check ntp installation on debian - command: dpkg -s ntp - register: ntp_pkg_query - ignore_errors: true - check_mode: no - changed_when: false - when: - - ansible_os_family == 'Debian' - -- name: install ntp on debian - package: - name: ntp - state: present diff --git a/roles/ceph-docker-common/tasks/checks/check_ntp_rpm.yml b/roles/ceph-docker-common/tasks/checks/check_ntp_rpm.yml deleted file mode 100644 index 59f6f8c8d..000000000 --- a/roles/ceph-docker-common/tasks/checks/check_ntp_rpm.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- -- name: check ntp installation on redhat or suse - command: rpm -q ntp - args: - warn: no - register: ntp_pkg_query - ignore_errors: true - check_mode: no - changed_when: false - when: - - ansible_os_family in ['RedHat', 'Suse'] - -- name: install ntp on redhat or suse - package: - name: ntp - state: present diff --git a/roles/ceph-docker-common/tasks/main.yml b/roles/ceph-docker-common/tasks/main.yml index f2e621a32..093d56d6d 100644 --- a/roles/ceph-docker-common/tasks/main.yml +++ b/roles/ceph-docker-common/tasks/main.yml @@ -30,26 +30,6 @@ - not ceph_current_status.get('rc', 1) == 0 - not rolling_update | default(false) -- name: include misc/ntp_atomic.yml - include_tasks: misc/ntp_atomic.yml - when: - - is_atomic - - ansible_os_family == 'RedHat' - - ntp_service_enabled - -- name: include misc/ntp_rpm.yml - include_tasks: misc/ntp_rpm.yml - when: - - not is_atomic - - ansible_os_family in ['RedHat', 'Suse'] - - ntp_service_enabled - -- name: include misc/ntp_debian.yml - include_tasks: misc/ntp_debian.yml - when: - - ansible_os_family == 'Debian' - - ntp_service_enabled - - name: include fetch_image.yml include_tasks: fetch_image.yml tags: diff --git a/roles/ceph-docker-common/tasks/misc/ntp_atomic.yml b/roles/ceph-docker-common/tasks/misc/ntp_atomic.yml deleted file mode 100644 index fe6e268cf..000000000 --- a/roles/ceph-docker-common/tasks/misc/ntp_atomic.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- -- name: include ../checks/check_ntp_atomic.yml - include_tasks: ../checks/check_ntp_atomic.yml - when: is_atomic - -- name: start the ntp service - service: - name: chronyd - enabled: yes - state: started - when: - - ntp_pkg_query.rc == 0 diff --git a/roles/ceph-docker-common/tasks/misc/ntp_debian.yml b/roles/ceph-docker-common/tasks/misc/ntp_debian.yml deleted file mode 100644 index 6441daa40..000000000 --- a/roles/ceph-docker-common/tasks/misc/ntp_debian.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -- name: include ../checks/check_ntp_debian.yml - include_tasks: ../checks/check_ntp_debian.yml - when: - - ansible_os_family == 'Debian' - -- name: start the ntp service - service: - name: ntp - enabled: yes - state: started - when: - - ntp_pkg_query.rc == 0 diff --git a/roles/ceph-docker-common/tasks/misc/ntp_rpm.yml b/roles/ceph-docker-common/tasks/misc/ntp_rpm.yml deleted file mode 100644 index 6f2a58a57..000000000 --- a/roles/ceph-docker-common/tasks/misc/ntp_rpm.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -- name: include ../checks/check_ntp_rpm.yml - include_tasks: ../checks/check_ntp_rpm.yml - when: - - ansible_os_family in ['RedHat', 'Suse'] - -- name: start the ntp service - service: - name: ntpd - enabled: yes - state: started - when: - - ntp_pkg_query.rc == 0