From 290b83cd0655e355e61677a4b3934ee6400ae38b Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:09:28 -0400 Subject: [PATCH 01/11] group_vars: convert ceph_stable_rh_storage to ceph_rhcs Signed-off-by: Alfredo Deza Resolves: issue#811 --- group_vars/all.sample | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/group_vars/all.sample b/group_vars/all.sample index 4d3e7e15a..0779a6269 100644 --- a/group_vars/all.sample +++ b/group_vars/all.sample @@ -144,15 +144,15 @@ dummy: # time. Please use ELRepo's latest upstream 4.x kernels if you want to run CephFS # on RHEL 7. # -#ceph_stable_rh_storage: false +#ceph_rhcs: false # This will affect how/what repositories are enabled depending on the desired # version. The next version will use "2" not "2.0" which would not work. -#ceph_stable_rh_storage_version: 1.3 # next version is 2 -#ceph_stable_rh_storage_cdn_install: false # assumes all the nodes can connect to cdn.redhat.com -#ceph_stable_rh_storage_iso_install: false # usually used when nodes don't have access to cdn.redhat.com -#ceph_stable_rh_storage_iso_path: -#ceph_stable_rh_storage_mount_path: /tmp/rh-storage-mount -#ceph_stable_rh_storage_repository_path: /tmp/rh-storage-repo # where to copy iso's content +#ceph_rhcs_version: 1.3 # next version is 2 +#ceph_rhcs_cdn_install: false # assumes all the nodes can connect to cdn.redhat.com +#ceph_rhcs_iso_install: false # usually used when nodes don't have access to cdn.redhat.com +#ceph_rhcs_iso_path: +#ceph_rhcs_mount_path: /tmp/rh-storage-mount +#ceph_rhcs_repository_path: /tmp/rh-storage-repo # where to copy iso's content # UBUNTU CLOUD ARCHIVE From a37e2f7a1ce5b743c6839b5afa163b6d1341f4d3 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:26:44 -0400 Subject: [PATCH 02/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in README Signed-off-by: Alfredo Deza Resolves: issue#811 --- roles/ceph-common/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/ceph-common/README.md b/roles/ceph-common/README.md index 6c1b81fd1..3a09fae4e 100644 --- a/roles/ceph-common/README.md +++ b/roles/ceph-common/README.md @@ -25,7 +25,7 @@ Have a look at `defaults/main.yml`. * Install source, choose one of these: * `ceph_stable` * `ceph_dev` - * `ceph_stable_rh_storage` + * `ceph_rhcs` * `ceph_custom` * `journal_size` * `monitor_interface` From 492518a2cd97306fa0877b8cfb5b754709211e38 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:27:01 -0400 Subject: [PATCH 03/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in defaults Signed-off-by: Alfredo Deza Resolves: issue#811 --- roles/ceph-common/defaults/main.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/roles/ceph-common/defaults/main.yml b/roles/ceph-common/defaults/main.yml index fe9d16849..3f6dc4ccd 100644 --- a/roles/ceph-common/defaults/main.yml +++ b/roles/ceph-common/defaults/main.yml @@ -136,15 +136,15 @@ ceph_stable_redhat_distro: el7 # time. Please use ELRepo's latest upstream 4.x kernels if you want to run CephFS # on RHEL 7. # -ceph_stable_rh_storage: false +ceph_rhcs: false # This will affect how/what repositories are enabled depending on the desired # version. The next version will use "2" not "2.0" which would not work. -ceph_stable_rh_storage_version: 1.3 # next version is 2 -ceph_stable_rh_storage_cdn_install: false # assumes all the nodes can connect to cdn.redhat.com -ceph_stable_rh_storage_iso_install: false # usually used when nodes don't have access to cdn.redhat.com -#ceph_stable_rh_storage_iso_path: -ceph_stable_rh_storage_mount_path: /tmp/rh-storage-mount -ceph_stable_rh_storage_repository_path: /tmp/rh-storage-repo # where to copy iso's content +ceph_rhcs_version: 1.3 # next version is 2 +ceph_rhcs_cdn_install: false # assumes all the nodes can connect to cdn.redhat.com +ceph_rhcs_iso_install: false # usually used when nodes don't have access to cdn.redhat.com +#ceph_rhcs_iso_path: +ceph_rhcs_mount_path: /tmp/rh-storage-mount +ceph_rhcs_repository_path: /tmp/rh-storage-repo # where to copy iso's content # UBUNTU CLOUD ARCHIVE From b41c84bb0d91d1312e289b48d8339cb2ffa39680 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:27:43 -0400 Subject: [PATCH 04/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in repo template Signed-off-by: Alfredo Deza Resolves: issue#811 --- roles/ceph-common/templates/redhat_storage_repo.j2 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/roles/ceph-common/templates/redhat_storage_repo.j2 b/roles/ceph-common/templates/redhat_storage_repo.j2 index 45828a83c..16f57c483 100644 --- a/roles/ceph-common/templates/redhat_storage_repo.j2 +++ b/roles/ceph-common/templates/redhat_storage_repo.j2 @@ -1,21 +1,21 @@ # {{ ansible_managed }} [rh_storage_mon] name=Red Hat Ceph Storage - local packages for Ceph monitor -baseurl=file://{{ ceph_stable_rh_storage_repository_path }}/MON +baseurl=file://{{ ceph_rhcs_repository_path }}/MON enabled=1 gpgcheck=1 priority=1 [rh_storage_osd] name=Red Hat Ceph Storage - local packages for Ceph OSD -baseurl=file://{{ ceph_stable_rh_storage_repository_path }}/OSD +baseurl=file://{{ ceph_rhcs_repository_path }}/OSD enabled=1 gpgcheck=1 priority=1 [rh_storage_tools] name=Red Hat Ceph Storage - local packages for Ceph client, MDS, and RGW -baseurl=file://{{ ceph_stable_rh_storage_repository_path }}/Tools +baseurl=file://{{ ceph_rhcs_repository_path }}/Tools enabled=1 gpgcheck=1 priority=1 From 23051e7ea5658e1daf0ffb8e404d70fdc4805c94 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:28:03 -0400 Subject: [PATCH 05/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in main task Signed-off-by: Alfredo Deza Resolves: issue#811 --- roles/ceph-common/tasks/main.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/roles/ceph-common/tasks/main.yml b/roles/ceph-common/tasks/main.yml index cd87f5e70..54edb2256 100644 --- a/roles/ceph-common/tasks/main.yml +++ b/roles/ceph-common/tasks/main.yml @@ -11,15 +11,15 @@ - include: ./pre_requisites/prerequisite_rh_storage_iso_install.yml when: - - ceph_stable_rh_storage - - ceph_stable_rh_storage_iso_install + - ceph_rhcs + - ceph_rhcs_iso_install tags: - package-install - include: ./pre_requisites/prerequisite_rh_storage_cdn_install.yml when: - - ceph_stable_rh_storage - - ceph_stable_rh_storage_cdn_install + - ceph_rhcs + - ceph_rhcs_cdn_install - ansible_os_family == "RedHat" tags: - package-install @@ -27,28 +27,28 @@ - include: ./installs/install_on_redhat.yml when: ansible_os_family == 'RedHat' and - not ceph_stable_rh_storage_iso_install + not ceph_rhcs_iso_install tags: - package-install - include: ./installs/install_rh_storage_on_redhat.yml when: - ansible_distribution == "RedHat" - - ceph_stable_rh_storage + - ceph_rhcs tags: - package-install - include: ./installs/install_on_debian.yml when: - ansible_os_family == 'Debian' - - not ceph_stable_rh_storage + - not ceph_rhcs tags: - package-install - include: ./installs/install_rh_storage_on_debian.yml when: - ansible_os_family == 'Debian' - - ceph_stable_rh_storage + - ceph_rhcs tags: - package-install From efe2c9e518a6b177816706bc605c746f504e1c31 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:28:26 -0400 Subject: [PATCH 06/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in system checks Signed-off-by: Alfredo Deza Resolves: issue#811 --- roles/ceph-common/tasks/checks/check_system.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/ceph-common/tasks/checks/check_system.yml b/roles/ceph-common/tasks/checks/check_system.yml index 9338a3e5a..21e348c96 100644 --- a/roles/ceph-common/tasks/checks/check_system.yml +++ b/roles/ceph-common/tasks/checks/check_system.yml @@ -18,7 +18,7 @@ fail: msg: "Distribution not supported {{ ansible_distribution_version }} by Red Hat Ceph Storage, only RHEL 7.1" when: - - ceph_stable_rh_storage + - ceph_rhcs - ansible_distribution_version | version_compare('7.1', '<') - name: fail on unsupported distribution for ubuntu cloud archive From 30494497b0310cabfeabd18cb4972e3372e22779 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:28:55 -0400 Subject: [PATCH 07/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in mandatory vars Signed-off-by: Alfredo Deza Resolves: issue#811 --- .../ceph-common/tasks/checks/check_mandatory_vars.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/roles/ceph-common/tasks/checks/check_mandatory_vars.yml b/roles/ceph-common/tasks/checks/check_mandatory_vars.yml index e317589b7..ed800d992 100644 --- a/roles/ceph-common/tasks/checks/check_mandatory_vars.yml +++ b/roles/ceph-common/tasks/checks/check_mandatory_vars.yml @@ -16,18 +16,18 @@ - ceph_origin == 'upstream' - not ceph_stable - not ceph_dev - - not ceph_stable_rh_storage + - not ceph_rhcs - not ceph_stable_uca tags: - package-install - name: verify that a method was chosen for red hat storage fail: - msg: "choose between ceph_stable_rh_storage_cdn_install and ceph_stable_rh_storage_iso_install" + msg: "choose between ceph_rhcs_cdn_install and ceph_rhcs_iso_install" when: - - ceph_stable_rh_storage - - not ceph_stable_rh_storage_cdn_install - - not ceph_stable_rh_storage_iso_install + - ceph_rhcs + - not ceph_rhcs_cdn_install + - not ceph_rhcs_iso_install - ceph_origin == "upstream" tags: - package-install From 90730a7f4b86695be7e8ee7f5cb3203fd3cdb408 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:29:39 -0400 Subject: [PATCH 08/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs when installing rhs on debian Signed-off-by: Alfredo Deza Resolves: issue#811 --- .../installs/install_rh_storage_on_debian.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/roles/ceph-common/tasks/installs/install_rh_storage_on_debian.yml b/roles/ceph-common/tasks/installs/install_rh_storage_on_debian.yml index 8bc5452a9..b82ca8833 100644 --- a/roles/ceph-common/tasks/installs/install_rh_storage_on_debian.yml +++ b/roles/ceph-common/tasks/installs/install_rh_storage_on_debian.yml @@ -5,15 +5,15 @@ # intelligent way to determine the location of the key. - name: install the rh ceph storage repository key apt_key: - file: "{{ ceph_stable_rh_storage_repository_path }}/MON/release.asc" + file: "{{ ceph_rhcs_repository_path }}/MON/release.asc" state: present when: - - ceph_stable_rh_storage - - ceph_stable_rh_storage_iso_install + - ceph_rhcs + - ceph_rhcs_iso_install - name: add rh ceph storage repositories apt_repository: - repo: "deb file://{{ ceph_stable_rh_storage_repository_path }}/{{ item }}/ {{ ansible_lsb.codename }} main" + repo: "deb file://{{ ceph_rhcs_repository_path }}/{{ item }}/ {{ ansible_lsb.codename }} main" state: present changed_when: false with_items: @@ -22,14 +22,14 @@ - "Tools" - "Agent" when: - - ceph_stable_rh_storage - - ceph_stable_rh_storage_iso_install + - ceph_rhcs + - ceph_rhcs_iso_install - name: add the red hat storage apt-key apt_key: data: "{{ lookup('file', role_path+'/files/cephstablerhcs.asc') }}" state: present - when: not ceph_stable_rh_storage_iso_install + when: not ceph_rhcs_iso_install - name: install dependencies apt: From a4036459443a07da3a9f2354dc8641a7f786569a Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:30:06 -0400 Subject: [PATCH 09/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs when installing rhs on redhat Signed-off-by: Alfredo Deza Resolves: issue#811 --- .../tasks/installs/install_rh_storage_on_redhat.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/roles/ceph-common/tasks/installs/install_rh_storage_on_redhat.yml b/roles/ceph-common/tasks/installs/install_rh_storage_on_redhat.yml index dfdfba574..b950e1136 100644 --- a/roles/ceph-common/tasks/installs/install_rh_storage_on_redhat.yml +++ b/roles/ceph-common/tasks/installs/install_rh_storage_on_redhat.yml @@ -1,10 +1,10 @@ --- - name: install red hat storage repository key rpm_key: - key: "{{ ceph_stable_rh_storage_repository_path }}/RPM-GPG-KEY-redhat-release" + key: "{{ ceph_rhcs_repository_path }}/RPM-GPG-KEY-redhat-release" state: present when: - - ceph_stable_rh_storage_iso_install + - ceph_rhcs_iso_install - name: add red hat storage repository template: @@ -14,7 +14,7 @@ group: root mode: 0644 when: - - ceph_stable_rh_storage_iso_install + - ceph_rhcs_iso_install - name: install dependencies yum: From 1681a3ecb672042e0d366c41ffa49a44b5e5f676 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:30:41 -0400 Subject: [PATCH 10/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in prerequisites for cdn install Signed-off-by: Alfredo Deza Resolves: issue#811 --- .../prerequisite_rh_storage_cdn_install.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_cdn_install.yml b/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_cdn_install.yml index 4c1583066..d2d7ab864 100644 --- a/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_cdn_install.yml +++ b/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_cdn_install.yml @@ -5,42 +5,42 @@ changed_when: false - name: check if the red hat storage monitor repo is already present - shell: yum --noplugins --cacheonly repolist | grep -sq rhel-7-server-rhceph-{{ ceph_stable_rh_storage_version }}-mon-rpms + shell: yum --noplugins --cacheonly repolist | grep -sq rhel-7-server-rhceph-{{ ceph_rhcs_version }}-mon-rpms changed_when: false failed_when: false register: rh_storage_mon_repo when: mon_group_name in group_names - name: enable red hat storage monitor repository - command: subscription-manager repos --enable rhel-7-server-rhceph-{{ ceph_stable_rh_storage_version }}-mon-rpms + command: subscription-manager repos --enable rhel-7-server-rhceph-{{ ceph_rhcs_version }}-mon-rpms changed_when: false when: - mon_group_name in group_names - rh_storage_mon_repo.rc != 0 - name: check if the red hat storage osd repo is already present - shell: yum --noplugins --cacheonly repolist | grep -sq rhel-7-server-rhceph-{{ ceph_stable_rh_storage_version }}-osd-rpms + shell: yum --noplugins --cacheonly repolist | grep -sq rhel-7-server-rhceph-{{ ceph_rhcs_version }}-osd-rpms changed_when: false failed_when: false register: rh_storage_osd_repo when: osd_group_name in group_names - name: enable red hat storage osd repository - command: subscription-manager repos --enable rhel-7-server-rhceph-{{ ceph_stable_rh_storage_version }}-osd-rpms + command: subscription-manager repos --enable rhel-7-server-rhceph-{{ ceph_rhcs_version }}-osd-rpms changed_when: false when: - osd_group_name in group_names - rh_storage_osd_repo.rc != 0 - name: check if the red hat storage rados gateway repo is already present - shell: yum --noplugins --cacheonly repolist | grep -sq rhel-7-server-rhceph-{{ ceph_stable_rh_storage_version }}-tools-rpms + shell: yum --noplugins --cacheonly repolist | grep -sq rhel-7-server-rhceph-{{ ceph_rhcs_version }}-tools-rpms changed_when: false failed_when: false register: rh_storage_rgw_repo when: rgw_group_name in group_names - name: enable red hat storage rados gateway repository - command: subscription-manager repos --enable rhel-7-server-rhceph-{{ ceph_stable_rh_storage_version }}-tools-rpms + command: subscription-manager repos --enable rhel-7-server-rhceph-{{ ceph_rhcs_version }}-tools-rpms changed_when: false when: - rgw_group_name in group_names From 3037b756243fd2d62dab9e391df2934bbcb45c5e Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Fri, 12 Aug 2016 11:31:01 -0400 Subject: [PATCH 11/11] ceph-common: convert ceph_stable_rh_storage to ceph_rhcs in prerequisites for iso install Signed-off-by: Alfredo Deza Resolves: issue#811 --- .../prerequisite_rh_storage_iso_install.yml | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_iso_install.yml b/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_iso_install.yml index c376e6b56..e589fec34 100644 --- a/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_iso_install.yml +++ b/roles/ceph-common/tasks/pre_requisites/prerequisite_rh_storage_iso_install.yml @@ -4,40 +4,40 @@ path: "{{ item }}" state: directory with_items: - - "{{ ceph_stable_rh_storage_mount_path }}" - - "{{ ceph_stable_rh_storage_repository_path }}" + - "{{ ceph_rhcs_mount_path }}" + - "{{ ceph_rhcs_repository_path }}" - name: ensure destination iso directory exists file: - path: "{{ ceph_stable_rh_storage_iso_path | dirname }}" + path: "{{ ceph_rhcs_iso_path | dirname }}" state: directory recurse: yes - when: "'{{ ceph_stable_rh_storage_iso_path | dirname }}' != '/'" + when: "'{{ ceph_rhcs_iso_path | dirname }}' != '/'" - name: fetch the red hat storage iso from the ansible server copy: - src: "{{ ceph_stable_rh_storage_iso_path }}" - dest: "{{ ceph_stable_rh_storage_iso_path }}" + src: "{{ ceph_rhcs_iso_path }}" + dest: "{{ ceph_rhcs_iso_path }}" -# assumption: ceph_stable_rh_storage_mount_path does not specify directory +# assumption: ceph_rhcs_mount_path does not specify directory - name: mount red hat storage iso file mount: - name: "{{ ceph_stable_rh_storage_mount_path }}" - src: "{{ ceph_stable_rh_storage_iso_path }}" + name: "{{ ceph_rhcs_mount_path }}" + src: "{{ ceph_rhcs_iso_path }}" fstype: iso9660 opts: ro,loop,noauto passno: 2 state: mounted - name: copy red hat storage iso content - shell: cp -r {{ ceph_stable_rh_storage_mount_path }}/* {{ ceph_stable_rh_storage_repository_path }} + shell: cp -r {{ ceph_rhcs_mount_path }}/* {{ ceph_rhcs_repository_path }} args: - creates: "{{ ceph_stable_rh_storage_repository_path }}/README" + creates: "{{ ceph_rhcs_repository_path }}/README" - name: unmount red hat storage iso file mount: - name: "{{ ceph_stable_rh_storage_mount_path }}" - src: "{{ ceph_stable_rh_storage_iso_path }}" + name: "{{ ceph_rhcs_mount_path }}" + src: "{{ ceph_rhcs_iso_path }}" fstype: iso9660 state: unmounted