openstack-ansible-ceph_client/tasks/ceph_preinstall_yum.yml
Marc Gariepy 573ea17a10 Add priority of 50 for yum ceph repository on CentOS
Change-Id: Iaa4c76b3c09caf4042afec52d90c4af2faad8944
2017-04-05 08:26:41 -04:00

51 lines
1.3 KiB
YAML

---
# Copyright 2017 Marc Gariépy <gariepy.marc@gmail.com>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
- name: Add ceph rpm key
rpm_key:
key: "{{ ceph_gpg_keys }}"
state: "present"
register: add_keys
until: add_keys|success
failed_when: false
retries: 5
delay: 2
when:
- ceph_pkg_source == 'ceph'
- name: Add ceph repo
yum_repository:
name: ceph
description: "Ceph packages for $basearch"
file: ceph
baseurl: "{{ceph_yum_repo_url}}/$basearch"
gpgcheck: yes
enabled: yes
priority: 50
gpgkey: "{{ ceph_gpg_keys }}"
state: present
- name: Add ceph noarch repo
yum_repository:
name: ceph-noarch
description: "Ceph noarch packages"
file: ceph
baseurl: "{{ceph_yum_repo_url}}/noarch"
gpgcheck: yes
enabled: yes
priority: 50
gpgkey: "{{ ceph_gpg_keys }}"
state: present