mirror of https://github.com/ceph/ceph-ansible.git
ceph-iscsi: add ceph-iscsi stable repositories
This commit adds the support of the ceph-iscsi stable repository when use ceph_repository community instead of always using the devel repositories. We're still using the devel repositories for rtslib and tcmu-runner in both cases (dev and community). Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>pull/4653/head
parent
82495eaf97
commit
f2cb937193
|
@ -24,45 +24,40 @@
|
||||||
- ceph-iscsi-config
|
- ceph-iscsi-config
|
||||||
when: not use_new_ceph_iscsi | bool
|
when: not use_new_ceph_iscsi | bool
|
||||||
|
|
||||||
- name: set_fact ceph_iscsi_repos
|
|
||||||
set_fact:
|
|
||||||
ceph_iscsi_repos: "{{ common_repos + iscsi_base }}"
|
|
||||||
|
|
||||||
- name: set_fact ceph_iscsi_pkgs
|
|
||||||
set_fact:
|
|
||||||
ceph_iscsi_pkgs: "{{ common_pkgs + iscsi_base }}"
|
|
||||||
|
|
||||||
- name: when ceph_iscsi_config_dev is true
|
- name: when ceph_iscsi_config_dev is true
|
||||||
when:
|
when:
|
||||||
- ceph_origin == 'repository'
|
- ceph_origin == 'repository'
|
||||||
- ceph_repository == 'dev'
|
- ceph_repository in ['dev', 'community']
|
||||||
- ceph_iscsi_config_dev | bool
|
- ceph_iscsi_config_dev | bool
|
||||||
block:
|
block:
|
||||||
- name: fetch ceph-iscsi development repository
|
- name: ceph-iscsi dependency repositories
|
||||||
uri:
|
get_url:
|
||||||
url: https://shaman.ceph.com/api/repos/{{ item }}/{{ ceph_dev_branch }}/{{ ceph_dev_sha1 }}/{{ ansible_distribution | lower }}/{{ ansible_distribution_major_version }}/repo
|
url: 'https://shaman.ceph.com/api/repos/{{ item }}/{{ ceph_dev_branch }}/{{ ceph_dev_sha1 }}/{{ ansible_distribution | lower }}/{{ ansible_distribution_major_version }}/repo'
|
||||||
return_content: yes
|
dest: '/etc/yum.repos.d/{{ item }}-dev.repo'
|
||||||
register: ceph_iscsi_config_dev_yum_repo
|
force: true
|
||||||
with_items: "{{ ceph_iscsi_repos }}"
|
with_items: "{{ common_repos }}"
|
||||||
|
|
||||||
- name: configure ceph-iscsi-config development repository
|
- name: ceph-iscsi development repository
|
||||||
copy:
|
get_url:
|
||||||
content: "{{ item.0.content }}"
|
url: 'https://shaman.ceph.com/api/repos/{{ item }}/{{ ceph_dev_branch }}/{{ ceph_dev_sha1 }}/{{ ansible_distribution | lower }}/{{ ansible_distribution_major_version }}/repo'
|
||||||
dest: "/etc/yum.repos.d/{{ item.1 }}-dev.repo"
|
dest: '/etc/yum.repos.d/{{ item }}-dev.repo'
|
||||||
owner: root
|
force: true
|
||||||
group: root
|
with_items: '{{ iscsi_base }}'
|
||||||
backup: yes
|
when: ceph_repository == 'dev'
|
||||||
with_together:
|
|
||||||
- "{{ ceph_iscsi_config_dev_yum_repo.results }}"
|
- name: ceph-iscsi stable repository
|
||||||
- "{{ ceph_iscsi_repos }}"
|
get_url:
|
||||||
|
url: 'https://download.ceph.com/ceph-iscsi/{{ "3" if use_new_ceph_iscsi | bool else "2" }}/rpm/el{{ ansible_distribution_major_version }}/ceph-iscsi.repo'
|
||||||
|
dest: /etc/yum.repos.d/ceph-iscsi.repo
|
||||||
|
force: true
|
||||||
|
when: ceph_repository == 'community'
|
||||||
|
|
||||||
- name: install ceph iscsi package
|
- name: install ceph iscsi package
|
||||||
package:
|
package:
|
||||||
name: "{{ item }}"
|
name: "{{ common_pkgs + iscsi_base }}"
|
||||||
state: "{{ (upgrade_ceph_packages|bool) | ternary('latest','present') }}"
|
state: "{{ (upgrade_ceph_packages|bool) | ternary('latest','present') }}"
|
||||||
register: result
|
register: result
|
||||||
until: result is succeeded
|
until: result is succeeded
|
||||||
with_items: "{{ ceph_iscsi_pkgs }}"
|
|
||||||
|
|
||||||
- name: check the status of the target.service override
|
- name: check the status of the target.service override
|
||||||
stat:
|
stat:
|
||||||
|
|
Loading…
Reference in New Issue