Use 'dnf' when configuring repo in Fedora
Use 'dnf' instead of 'yum' in Fedora as Fedora no longer have 'yum' binary. Also Fedora do not need yum-plugin-priorities to manage repo priorities. Also Do not Enable rdo-qemu-ev repo for Fedora. Change-Id: Id33c970e810ea48d74b9095b0e505d4e71be005a
This commit is contained in:
parent
a13141f8e9
commit
7c4183e336
@ -115,7 +115,7 @@ class openstack_extras::repo::redhat::redhat(
|
|||||||
create_resources('yumrepo', $rdo_hash, $_repo_defaults)
|
create_resources('yumrepo', $rdo_hash, $_repo_defaults)
|
||||||
}
|
}
|
||||||
|
|
||||||
if $manage_virt {
|
if $manage_virt and ($::operatingsystem != 'Fedora') {
|
||||||
$virt_hash = {
|
$virt_hash = {
|
||||||
'rdo-qemu-ev' => {
|
'rdo-qemu-ev' => {
|
||||||
'baseurl' => "${centos_mirror_url}/centos/7/virt/\$basearch/kvm-common/",
|
'baseurl' => "${centos_mirror_url}/centos/7/virt/\$basearch/kvm-common/",
|
||||||
@ -174,7 +174,7 @@ class openstack_extras::repo::redhat::redhat(
|
|||||||
resources { 'yumrepo': purge => true }
|
resources { 'yumrepo': purge => true }
|
||||||
}
|
}
|
||||||
|
|
||||||
if $manage_priorities {
|
if $manage_priorities and ($::operatingsystem != 'Fedora') {
|
||||||
exec { 'installing_yum-plugin-priorities':
|
exec { 'installing_yum-plugin-priorities':
|
||||||
command => '/usr/bin/yum install -y yum-plugin-priorities',
|
command => '/usr/bin/yum install -y yum-plugin-priorities',
|
||||||
logoutput => 'on_failure',
|
logoutput => 'on_failure',
|
||||||
@ -189,9 +189,16 @@ class openstack_extras::repo::redhat::redhat(
|
|||||||
Yumrepo<||> -> Package<||>
|
Yumrepo<||> -> Package<||>
|
||||||
}
|
}
|
||||||
|
|
||||||
exec { 'yum_refresh':
|
if ($::operatingsystem == 'Fedora') {
|
||||||
command => '/usr/bin/yum clean all',
|
exec { 'yum_refresh':
|
||||||
refreshonly => true,
|
command => '/usr/bin/dnf clean all',
|
||||||
} -> Package <||>
|
refreshonly => true,
|
||||||
|
} -> Package <||>
|
||||||
|
} else {
|
||||||
|
exec { 'yum_refresh':
|
||||||
|
command => '/usr/bin/yum clean all',
|
||||||
|
refreshonly => true,
|
||||||
|
} -> Package <||>
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user