Unify EPEL gpg key and repo provisioning
At the moment we do install EPEL repo in multiple other roles, like lxc_hosts or systemd_mount. We're trying to be consistent in ways of adding them, while ceph_client was slightly different, by carrying on GPG keys in-repo instead of fetching them from `centos_epel_key` url. With this patch we unify approach with other roles and reducing maintenance costs of the repo when adding new distributions Change-Id: I407256dc6eee3365c4f8c191a1f50717f0b35fa8 Related-Bug: #2013276
This commit is contained in:
parent
5215b796c0
commit
7a70556e15
@ -121,3 +121,7 @@ ceph_extra_config_groups:
|
||||
ceph_extra_compute_group: nova_compute
|
||||
|
||||
ceph_client_ceph_conf_overrides: "{{ ceph_conf_overrides | default({}) }}"
|
||||
|
||||
# CentOS repos
|
||||
ceph_centos_epel_mirror: "{{ centos_epel_mirror | default('http://download.fedoraproject.org/pub/epel') }}"
|
||||
ceph_centos_epel_key: "{{ centos_epel_key | default('http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-' ~ ansible_facts['distribution_major_version']) }}"
|
||||
|
@ -1,29 +0,0 @@
|
||||
-----BEGIN PGP PUBLIC KEY BLOCK-----
|
||||
Version: GnuPG v1.4.11 (GNU/Linux)
|
||||
|
||||
mQINBFKuaIQBEAC1UphXwMqCAarPUH/ZsOFslabeTVO2pDk5YnO96f+rgZB7xArB
|
||||
OSeQk7B90iqSJ85/c72OAn4OXYvT63gfCeXpJs5M7emXkPsNQWWSju99lW+AqSNm
|
||||
jYWhmRlLRGl0OO7gIwj776dIXvcMNFlzSPj00N2xAqjMbjlnV2n2abAE5gq6VpqP
|
||||
vFXVyfrVa/ualogDVmf6h2t4Rdpifq8qTHsHFU3xpCz+T6/dGWKGQ42ZQfTaLnDM
|
||||
jToAsmY0AyevkIbX6iZVtzGvanYpPcWW4X0RDPcpqfFNZk643xI4lsZ+Y2Er9Yu5
|
||||
S/8x0ly+tmmIokaE0wwbdUu740YTZjCesroYWiRg5zuQ2xfKxJoV5E+Eh+tYwGDJ
|
||||
n6HfWhRgnudRRwvuJ45ztYVtKulKw8QQpd2STW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bKPOzTWbsP45awcmivdrS74P6mL84WfkghipdmcoyVb1B8ZP4Y/Ke0RXOnLhNe
|
||||
CfrXXvuW+Pvg2RTfwRDtehGQPAgXbmLmz2ZkV69RGIr54HJv84NDbqZovRTMr7gL
|
||||
9k3ciCzXCiYQgM8yAyGHV0KEhFSQ1HV7gMnt9UmxbxBE2pGU7vu3CwjYga5DpwU7
|
||||
w5wu1TmM5KgZtZvuWOTDnqDLf0cKoIbW8FeeCOn24elcj32bnQDuF9DPey1mqcvT
|
||||
/yEo/Ushyz6CVYxN8DGgcy2M9JOsnmjDx02h6qgWGWDuKgb9jZrvRedpAQCeemEd
|
||||
fhEs6ihqVxRFl16HxC4EVijybhAL76SsM2nbtIqW1apBQJQpXWtQwwdvgTVpdEtE
|
||||
r4ArVJYX5LrswnWEQMOelugUG6S3ZjMfcyOa/O0364iY73vyVgaYK+2XtT2usMux
|
||||
VL469Kj5m13T6w==
|
||||
=Mjs/
|
||||
-----END PGP PUBLIC KEY BLOCK-----
|
@ -13,33 +13,27 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
- name: Copy EPEL gpg keyfile to the key location
|
||||
copy:
|
||||
src: "gpg/{{ item.key | basename }}"
|
||||
dest: "{{ item.key }}"
|
||||
mode: '0644'
|
||||
with_items: "{{ epel_gpg_keys }}"
|
||||
when:
|
||||
- ansible_facts['pkg_mgr'] == 'dnf'
|
||||
|
||||
- name: Install EPEL gpg keys
|
||||
rpm_key: "{{ key }}"
|
||||
with_items: "{{ epel_gpg_keys }}"
|
||||
loop_control:
|
||||
loop_var: key
|
||||
when:
|
||||
- ansible_facts['pkg_mgr'] == 'dnf'
|
||||
register: _add_epel_keys
|
||||
until: _add_epel_keys is success
|
||||
- name: Download EPEL gpg keys
|
||||
get_url:
|
||||
url: "{{ ceph_centos_epel_key }}"
|
||||
dest: /etc/pki/rpm-gpg
|
||||
register: _get_yum_keys
|
||||
until: _get_yum_keys is success
|
||||
retries: 5
|
||||
delay: 2
|
||||
|
||||
- name: Install EPEL gpg keys
|
||||
rpm_key:
|
||||
key: "/etc/pki/rpm-gpg/{{ ceph_centos_epel_key.split('/')[-1] }}"
|
||||
state: present
|
||||
|
||||
- name: Install the EPEL repository
|
||||
yum_repository:
|
||||
name: ceph-client-deps
|
||||
baseurl: "{{ (centos_epel_mirror | default ('http://download.fedoraproject.org/pub/epel')) ~ '/' ~ ansible_facts['distribution_major_version'] ~ '/Everything/' ~ ansible_facts['architecture'] }}"
|
||||
baseurl: "{{ ceph_centos_epel_mirror ~ '/' ~ ansible_facts['distribution_major_version'] ~ '/Everything/' ~ ansible_facts['architecture'] }}"
|
||||
description: "Extra Packages for Enterprise Linux {{ ansible_facts['distribution_major_version'] }} - $basearch"
|
||||
gpgcheck: yes
|
||||
gpgkey: "file:///etc/pki/rpm-gpg/{{ ceph_centos_epel_key.split('/')[-1] }}"
|
||||
enabled: yes
|
||||
state: present
|
||||
includepkgs: 'lttng-ust*, userspace-rcu, libbabeltrace, leveldb, liboath, fmt'
|
||||
|
@ -18,11 +18,6 @@ ceph_gpg_keys:
|
||||
# download.ceph.com/keys/release.asc
|
||||
- key: /etc/pki/rpm-gpg/ceph_com_keys_release
|
||||
|
||||
# EPEL GPG Keys
|
||||
epel_gpg_keys:
|
||||
# Extra Packages for Enterprise Linux
|
||||
- key: "/etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-{{ ansible_facts['distribution_major_version'] }}"
|
||||
|
||||
libvirt_packages:
|
||||
- libvirt-daemon-kvm
|
||||
- libvirt-client
|
||||
|
Loading…
Reference in New Issue
Block a user