diff --git a/roles/ceph-common/handlers/main.yml b/roles/ceph-common/handlers/main.yml deleted file mode 100644 index 9bcab1bfc..000000000 --- a/roles/ceph-common/handlers/main.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -- name: update apt cache if a repo was added - apt: - update_cache: yes - register: update_apt_cache - retries: 5 - delay: 2 - until: update_apt_cache | success \ No newline at end of file diff --git a/roles/ceph-common/tasks/installs/debian_community_repository.yml b/roles/ceph-common/tasks/installs/debian_community_repository.yml index 3471f0184..202ead939 100644 --- a/roles/ceph-common/tasks/installs/debian_community_repository.yml +++ b/roles/ceph-common/tasks/installs/debian_community_repository.yml @@ -8,5 +8,4 @@ apt_repository: repo: "deb {{ ceph_stable_repo }} {{ ceph_stable_distro_source | default(ansible_lsb.codename) }} main" state: present - update_cache: no - notify: update apt cache if a repo was added + update_cache: yes diff --git a/roles/ceph-common/tasks/installs/debian_dev_repository.yml b/roles/ceph-common/tasks/installs/debian_dev_repository.yml index e0d3195cb..758334434 100644 --- a/roles/ceph-common/tasks/installs/debian_dev_repository.yml +++ b/roles/ceph-common/tasks/installs/debian_dev_repository.yml @@ -9,5 +9,4 @@ apt_repository: repo: "{{ ceph_dev_deb_repo.content }}" state: present - update_cache: no - notify: update apt cache if a repo was added + update_cache: yes diff --git a/roles/ceph-common/tasks/installs/prerequisite_rhcs_cdn_install_debian.yml b/roles/ceph-common/tasks/installs/prerequisite_rhcs_cdn_install_debian.yml index 5a43e92a0..96e07d0b6 100644 --- a/roles/ceph-common/tasks/installs/prerequisite_rhcs_cdn_install_debian.yml +++ b/roles/ceph-common/tasks/installs/prerequisite_rhcs_cdn_install_debian.yml @@ -8,10 +8,9 @@ apt_repository: repo: "deb {{ ceph_rhcs_cdn_debian_repo }}{{ ceph_rhcs_cdn_debian_repo_version }}/{{ item.repo }} {{ ceph_stable_distro_source | default(ansible_lsb.codename) }} main" state: present - update_cache: no + update_cache: yes with_items: - { repo: "MON", configure: (mon_group_name in group_names or mgr_group_name in group_names) } - { repo: "OSD", configure: (osd_group_name in group_names) } - { repo: "Tools", configure: (rgw_group_name in group_names or mds_group_name in group_names or nfs_group_name in group_names or iscsi_gw_group_name in group_names or client_group_name in group_names) } when: item.configure - notify: update apt cache if a repo was added diff --git a/roles/ceph-common/tasks/installs/prerequisite_rhcs_iso_install_debian.yml b/roles/ceph-common/tasks/installs/prerequisite_rhcs_iso_install_debian.yml index 7671e09f6..8b6c70327 100644 --- a/roles/ceph-common/tasks/installs/prerequisite_rhcs_iso_install_debian.yml +++ b/roles/ceph-common/tasks/installs/prerequisite_rhcs_iso_install_debian.yml @@ -52,9 +52,8 @@ apt_repository: repo: "deb file://{{ ceph_rhcs_repository_path }}/{{ item }} {{ ansible_lsb.codename }} main" state: present - update_cache: no + update_cache: yes with_items: - MON - OSD - Tools - notify: update apt cache if a repo was added