Instead of a custom task, use epel_customizationj

Signed-off-by: Patrick Uiterwijk <puiterwijk@redhat.com>
This commit is contained in:
Patrick Uiterwijk 2015-12-20 01:51:03 +00:00
parent e3d9de7fe2
commit 375eaa9ed4
5 changed files with 7 additions and 8 deletions

View file

@ -13,7 +13,7 @@ libdir: /usr/lib64
# Most EL systems need default EPEL repos.
# Some systems (notably fed-cloud*) need to get their own
# EPEL files because EPEL overrides packages in their core repos.
use_default_epel: true
epel_customization: none
# example of ports for default iptables
# tcp_ports: [ 22, 80, 443 ]

View file

@ -1,4 +1,4 @@
---
freezes: false
use_default_epel: false
epel_customization: cloud

View file

@ -4,10 +4,6 @@
- authorized_key: user=root key="{{ lookup('file', files + '/fedora-cloud/fed09-ssh-key.pub') }}"
- template: src={{ files }}/fedora-cloud/hosts dest=/etc/hosts owner=root mode=0644
- name: Copy customized EPEL7 repo
copy: src=cloud-epel7.repo dest=/etc/yum.repos.d/cloud-epel7.repo
owner=root group=root mode=0644
- name: Enable nested virtualization
copy: content="options kvm_intel nested=1" dest=/etc/modprobe.d/nested_virt.conf
owner=root group=root mode=0644

View file

@ -8,8 +8,11 @@
- yumrepos
- name: put epel repos on el systems
action: copy src="{{ files }}/common/epel{{ ansible_distribution_major_version }}.repo" dest="/etc/yum.repos.d/epel{{ ansible_distribution_major_version }}.repo"
when: ((ansible_distribution == 'RedHat' or ansible_distribution == 'CentOS') and use_default_epel)
action: copy src="{{ item }}.repo" dest="/etc/yum.repos.d/epel{{ ansible_distribution_major_version }}.repo"
when: (ansible_distribution == 'RedHat' or ansible_distribution == 'CentOS')
with_first_found:
- {{ files }}/common/epel{{ epel_customization }}.repo
- {{ files }}/common/epel{{ ansible_distribution_major_version }}.repo
tags:
- config
- packages