repos: configure RDO Virtualization repository
Introduce manage_virt boolean (True by default) to whether or not configure RDO CentOS QEMU EV repository, required when deploying OpenStack Newton with RDO repositories. Change-Id: If62801a4975039714d9986a548b2144e448e00f7
This commit is contained in:
parent
e361c88af9
commit
bec2257397
20
files/RPM-GPG-KEY-CentOS-SIG-Virtualization
Normal file
20
files/RPM-GPG-KEY-CentOS-SIG-Virtualization
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
-----BEGIN PGP PUBLIC KEY BLOCK-----
|
||||||
|
Version: GnuPG v2.0.22 (GNU/Linux)
|
||||||
|
|
||||||
|
mQENBFWB31YBCAC4dFmTzBDOcq4R1RbvQXLkyYfF+yXcsMA5kwZy7kjxnFqBoNPv
|
||||||
|
aAjFm3e5huTw2BMZW0viLGJrHZGnsXsE5iNmzom2UgCtrvcG2f65OFGlC1HZ3ajA
|
||||||
|
8ZIfdgNQkPpor61xqBCLzIsp55A7YuPNDvatk/+MqGdNv8Ug7iVmhQvI0p1bbaZR
|
||||||
|
0GuavmC5EZ/+mDlZ2kHIQOUoInHqLJaX7iw46iLRUnvJ1vATOzTnKidoFapjhzIt
|
||||||
|
i4ZSIRaalyJ4sT+oX4CoRzerNnUtIe2k9Hw6cEu4YKGCO7nnuXjMKz7Nz5GgP2Ou
|
||||||
|
zIA/fcOmQkSGcn7FoXybWJ8DqBExvkJuDljPABEBAAG0bENlbnRPUyBWaXJ0dWFs
|
||||||
|
aXphdGlvbiBTSUcgKGh0dHA6Ly93aWtpLmNlbnRvcy5vcmcvU3BlY2lhbEludGVy
|
||||||
|
ZXN0R3JvdXAvVmlydHVhbGl6YXRpb24pIDxzZWN1cml0eUBjZW50b3Mub3JnPokB
|
||||||
|
OQQTAQIAIwUCVYHfVgIbAwcLCQgHAwIBBhUIAgkKCwQWAgMBAh4BAheAAAoJEHrr
|
||||||
|
voJh6IBsRd0H/A62i5CqfftuySOCE95xMxZRw8+voWO84QS9zYvDEnzcEQpNnHyo
|
||||||
|
FNZTpKOghIDtETWxzpY2ThLixcZOTubT+6hUL1n+cuLDVMu4OVXBPoUkRy56defc
|
||||||
|
qkWR+UVwQitmlq1ngzwmqVZaB8Hf/mFZiB3B3Jr4dvVgWXRv58jcXFOPb8DdUoAc
|
||||||
|
S3u/FLvri92lCaXu08p8YSpFOfT5T55kFICeneqETNYS2E3iKLipHFOLh7EWGM5b
|
||||||
|
Wsr7o0r+KltI4Ehy/TjvNX16fa/t9p5pUs8rKyG8SZndxJCsk0MW55G9HFvQ0FmP
|
||||||
|
A6vX9WQmbP+ml7jsUxtEJ6MOGJ39jmaUvPc=
|
||||||
|
=ZzP+
|
||||||
|
-----END PGP PUBLIC KEY BLOCK-----
|
@ -14,6 +14,12 @@
|
|||||||
# for the RDO OpenStack repository provided by RedHat
|
# for the RDO OpenStack repository provided by RedHat
|
||||||
# Defaults to true
|
# Defaults to true
|
||||||
#
|
#
|
||||||
|
# [*manage_virt*]
|
||||||
|
# (optional) Whether to create a predefined yumrepo resource
|
||||||
|
# for the RDO CentOS QEMU EV epository provided by RedHat.
|
||||||
|
# This repository has been required starting from Newton.
|
||||||
|
# Defaults to true
|
||||||
|
#
|
||||||
# [*manage_epel*]
|
# [*manage_epel*]
|
||||||
# (optional) Whether to create a predefined yumrepo resource
|
# (optional) Whether to create a predefined yumrepo resource
|
||||||
# for the EPEL repository provided by RedHat
|
# for the EPEL repository provided by RedHat
|
||||||
@ -62,6 +68,7 @@
|
|||||||
class openstack_extras::repo::redhat::redhat(
|
class openstack_extras::repo::redhat::redhat(
|
||||||
$release = $::openstack_extras::repo::redhat::params::release,
|
$release = $::openstack_extras::repo::redhat::params::release,
|
||||||
$manage_rdo = true,
|
$manage_rdo = true,
|
||||||
|
$manage_virt = true,
|
||||||
$manage_epel = false,
|
$manage_epel = false,
|
||||||
$repo_hash = {},
|
$repo_hash = {},
|
||||||
$repo_defaults = {},
|
$repo_defaults = {},
|
||||||
@ -109,6 +116,24 @@ class openstack_extras::repo::redhat::redhat(
|
|||||||
create_resources('yumrepo', $rdo_hash, $_repo_defaults)
|
create_resources('yumrepo', $rdo_hash, $_repo_defaults)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if $manage_virt {
|
||||||
|
$virt_hash = {
|
||||||
|
'rdo-qemu-ev' => {
|
||||||
|
'baseurl' => "${centos_mirror_url}/centos/7/virt/\$basearch/kvm-common/",
|
||||||
|
'descr' => 'RDO CentOS-7 - QEMU EV',
|
||||||
|
'gpgkey' => 'file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-Virtualization',
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$virtkey_hash = { '/etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-Virtualization' => {
|
||||||
|
'source' => 'puppet:///modules/openstack_extras/RPM-GPG-KEY-CentOS-SIG-Virtualization'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
create_resources('file', $virtkey_hash, $_gpgkey_defaults)
|
||||||
|
create_resources('yumrepo', $virt_hash, $_repo_defaults)
|
||||||
|
}
|
||||||
|
|
||||||
if $manage_epel {
|
if $manage_epel {
|
||||||
if ($::osfamily == 'RedHat' and
|
if ($::osfamily == 'RedHat' and
|
||||||
$::operatingsystem != 'Fedora')
|
$::operatingsystem != 'Fedora')
|
||||||
|
6
releasenotes/notes/rdo-virt-a9fb3681cbc8419e.yaml
Normal file
6
releasenotes/notes/rdo-virt-a9fb3681cbc8419e.yaml
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
features:
|
||||||
|
- With a new boolean called manage_virt, allow to whether or not activate
|
||||||
|
RDO CentOS QEMU EV repository that is required when deploying OpenStack
|
||||||
|
Newton with RDO packaging. It's enabled by default to make deployments
|
||||||
|
working out of the box, but can be disabled.
|
@ -61,6 +61,17 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
|||||||
:notify => "Exec[yum_refresh]"
|
:notify => "Exec[yum_refresh]"
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
it { is_expected.to contain_yumrepo('rdo-qemu-ev').with(
|
||||||
|
:baseurl => "http://mirror.centos.org/centos/7/virt/$basearch/kvm-common/",
|
||||||
|
:descr => "RDO CentOS-7 - QEMU EV",
|
||||||
|
:gpgkey => "file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-Virtualization",
|
||||||
|
:enabled => '1',
|
||||||
|
:gpgcheck => '1',
|
||||||
|
:mirrorlist => 'absent',
|
||||||
|
:require => "Anchor[openstack_extras_redhat]",
|
||||||
|
:notify => "Exec[yum_refresh]"
|
||||||
|
)}
|
||||||
|
|
||||||
it { is_expected.to contain_exec('installing_yum-plugin-priorities').with(
|
it { is_expected.to contain_exec('installing_yum-plugin-priorities').with(
|
||||||
:command => '/usr/bin/yum install -y yum-plugin-priorities',
|
:command => '/usr/bin/yum install -y yum-plugin-priorities',
|
||||||
:logoutput => 'on_failure',
|
:logoutput => 'on_failure',
|
||||||
@ -104,6 +115,14 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
|||||||
:before => "Anchor[openstack_extras_redhat]"
|
:before => "Anchor[openstack_extras_redhat]"
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
it { is_expected.to contain_file('/etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-Virtualization').with(
|
||||||
|
:source => "puppet:///modules/openstack_extras/RPM-GPG-KEY-CentOS-SIG-Virtualization",
|
||||||
|
:owner => 'root',
|
||||||
|
:group => 'root',
|
||||||
|
:mode => '0644',
|
||||||
|
:before => "Anchor[openstack_extras_redhat]"
|
||||||
|
)}
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
describe 'with overridden release' do
|
describe 'with overridden release' do
|
||||||
@ -208,6 +227,15 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
|||||||
|
|
||||||
it { is_expected.to_not contain_yumrepo('rdo-release') }
|
it { is_expected.to_not contain_yumrepo('rdo-release') }
|
||||||
end
|
end
|
||||||
|
|
||||||
|
describe 'with rdo-virt management disabled' do
|
||||||
|
let :params do
|
||||||
|
default_params.merge!({ :manage_virt => false })
|
||||||
|
end
|
||||||
|
|
||||||
|
it { is_expected.to_not contain_yumrepo('rdo-qemu-ev') }
|
||||||
|
end
|
||||||
|
|
||||||
describe 'with manage_priorities disabled' do
|
describe 'with manage_priorities disabled' do
|
||||||
let :params do
|
let :params do
|
||||||
default_params.merge!({ :manage_priorities => false })
|
default_params.merge!({ :manage_priorities => false })
|
||||||
|
Loading…
Reference in New Issue
Block a user