--- /dev/null
+---
+- 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
repo: "deb {{ ceph_stable_repo }} {{ ceph_stable_distro_source | default(ansible_lsb.codename) }} main"
state: present
update_cache: no
- register: add_debian_apt_repo
+ notify: update apt cache if a repo was added
repo: "deb {{ ceph_custom_repo }} {{ ansible_lsb.codename }} main"
state: present
update_cache: no
- register: add_debian_apt_repo
+ notify: update apt cache if a repo was added
+
repo: "{{ ceph_dev_deb_repo.content }}"
state: present
update_cache: no
- register: add_debian_apt_repo
+ notify: update apt cache if a repo was added
repo: "deb {{ ceph_stable_repo_uca }} {{ ceph_stable_release_uca }} main"
state: present
update_cache: no
- register: add_debian_apt_repo
+ notify: update apt cache if a repo was added
+
when:
- ceph_origin == 'repository'
-- 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
- when:
- - add_debian_apt_repo is defined
- - add_debian_apt_repo.changed | default(false)
-
- name: update apt cache if cache_valid_time has expired
apt:
update_cache: yes
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
- register: add_debian_apt_repo
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
repo: "deb file://{{ ceph_rhcs_repository_path }}/{{ item }} {{ ansible_lsb.codename }} main"
state: present
update_cache: no
- register: add_debian_apt_repo
with_items:
- MON
- OSD
- Tools
+ notify: update apt cache if a repo was added