Move repo defaults to Ussuri
Move the EPEL testing to its own context because we were testing with a specified value that was not the default. Change-Id: Ib51009fb3584ea6ec8f423a5e8b2486714e47fe8
This commit is contained in:
parent
19f2d56122
commit
19e42853db
@ -4,7 +4,7 @@
|
||||
#
|
||||
class openstack_extras::repo::debian::params
|
||||
{
|
||||
$release = 'train'
|
||||
$release = 'ussuri'
|
||||
|
||||
$uca_name = 'ubuntu-cloud-archive'
|
||||
$uca_location = 'http://ubuntu-cloud.archive.canonical.com/ubuntu'
|
||||
|
@ -5,7 +5,7 @@
|
||||
#
|
||||
class openstack_extras::repo::redhat::params
|
||||
{
|
||||
$release = 'train'
|
||||
$release = 'ussuri'
|
||||
|
||||
$repo_defaults = { 'enabled' => '1',
|
||||
'gpgcheck' => '1',
|
||||
|
@ -201,4 +201,3 @@ class openstack_extras::repo::redhat::redhat(
|
||||
} -> Package <||>
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -13,7 +13,7 @@ describe 'openstack_extras::repo::debian::debian' do
|
||||
|
||||
let :paramclass_defaults do
|
||||
{
|
||||
:release => 'train'
|
||||
:release => 'ussuri'
|
||||
}
|
||||
end
|
||||
|
||||
@ -23,18 +23,18 @@ describe 'openstack_extras::repo::debian::debian' do
|
||||
|
||||
context 'with default parameters' do
|
||||
let :params do
|
||||
default_params
|
||||
{}
|
||||
end
|
||||
|
||||
it { should contain_apt__source('debian-openstack-backports').with(
|
||||
:location => 'http://stretch-train.debian.net/debian',
|
||||
:release => 'stretch-train-backports',
|
||||
:location => 'http://stretch-ussuri.debian.net/debian',
|
||||
:release => 'stretch-ussuri-backports',
|
||||
:repos => 'main',
|
||||
)}
|
||||
|
||||
it { should contain_apt__source('debian-openstack-backports-nochange').with(
|
||||
:location => 'http://stretch-train.debian.net/debian',
|
||||
:release => 'stretch-train-backports-nochange',
|
||||
:location => 'http://stretch-ussuri.debian.net/debian',
|
||||
:release => 'stretch-ussuri-backports-nochange',
|
||||
:repos => 'main'
|
||||
)}
|
||||
|
||||
|
@ -13,7 +13,7 @@ describe 'openstack_extras::repo::debian::ubuntu' do
|
||||
|
||||
let :paramclass_defaults do
|
||||
{
|
||||
:release => 'train'
|
||||
:release => 'ussuri'
|
||||
}
|
||||
end
|
||||
|
||||
@ -23,12 +23,12 @@ describe 'openstack_extras::repo::debian::ubuntu' do
|
||||
|
||||
context 'with default parameters' do
|
||||
let :params do
|
||||
default_params
|
||||
{}
|
||||
end
|
||||
|
||||
it { should contain_apt__source('ubuntu-cloud-archive').with(
|
||||
:location => 'http://ubuntu-cloud.archive.canonical.com/ubuntu',
|
||||
:release => 'trusty-updates/train',
|
||||
:release => 'trusty-updates/ussuri',
|
||||
:repos => 'main',
|
||||
)}
|
||||
|
||||
@ -127,7 +127,7 @@ describe 'openstack_extras::repo::debian::ubuntu' do
|
||||
|
||||
it { should contain_apt__source('ubuntu-cloud-archive').with(
|
||||
:location => 'http://mirror.dfw.rax.openstack.org/ubuntu-cloud-archive',
|
||||
:release => 'trusty-proposed/train',
|
||||
:release => 'trusty-proposed/ussuri',
|
||||
:repos => 'main',
|
||||
)}
|
||||
end
|
||||
|
@ -36,12 +36,12 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
||||
|
||||
context 'with default parameters' do
|
||||
let :params do
|
||||
default_params
|
||||
{}
|
||||
end
|
||||
|
||||
it { should contain_yumrepo('rdo-release').with(
|
||||
:baseurl => "http://mirror.centos.org/centos/7/cloud/$basearch/openstack-train/",
|
||||
:descr => 'OpenStack Train Repository',
|
||||
:baseurl => "http://mirror.centos.org/centos/7/cloud/$basearch/openstack-ussuri/",
|
||||
:descr => 'OpenStack Ussuri Repository',
|
||||
:gpgkey => 'file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-Cloud',
|
||||
:enabled => '1',
|
||||
:gpgcheck => '1',
|
||||
@ -69,33 +69,6 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
||||
:unless => '/usr/bin/rpm -qa | /usr/bin/grep -q yum-plugin-priorities',
|
||||
) }
|
||||
|
||||
# 'metalink' property is supported from Puppet 3.5
|
||||
if Puppet.version.to_f >= 3.5
|
||||
it { should contain_yumrepo('epel').with(
|
||||
:metalink => "https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=\$basearch",
|
||||
:descr => 'Extra Packages for Enterprise Linux 7 - $basearch',
|
||||
:gpgkey => 'file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7',
|
||||
:failovermethod => 'priority',
|
||||
:enabled => '1',
|
||||
:gpgcheck => '1',
|
||||
:mirrorlist => 'absent',
|
||||
:require => 'Anchor[openstack_extras_redhat]',
|
||||
:notify => 'Exec[yum_refresh]'
|
||||
)}
|
||||
else
|
||||
it { should contain_yumrepo('epel').with(
|
||||
:baseurl => "https://download.fedoraproject.org/pub/epel/7/\$basearch",
|
||||
:descr => 'Extra Packages for Enterprise Linux 7 - $basearch',
|
||||
:gpgkey => 'file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7',
|
||||
:failovermethod => 'priority',
|
||||
:enabled => '1',
|
||||
:gpgcheck => '1',
|
||||
:mirrorlist => 'absent',
|
||||
:require => 'Anchor[openstack_extras_redhat]',
|
||||
:notify => 'Exec[yum_refresh]'
|
||||
)}
|
||||
end
|
||||
|
||||
it { should contain_file('/etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-Cloud').with(
|
||||
:source => 'puppet:///modules/openstack_extras/RPM-GPG-KEY-CentOS-SIG-Cloud',
|
||||
:owner => 'root',
|
||||
@ -111,6 +84,8 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
||||
:mode => '0644',
|
||||
:before => 'Anchor[openstack_extras_redhat]'
|
||||
)}
|
||||
|
||||
it { should_not contain_yumrepo('epel') }
|
||||
end
|
||||
|
||||
context 'with overridden release' do
|
||||
@ -167,7 +142,6 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
||||
:require => 'Anchor[openstack_extras_redhat]',
|
||||
:notify => 'Exec[yum_refresh]'
|
||||
)}
|
||||
|
||||
end
|
||||
|
||||
context 'with overridden repo default' do
|
||||
@ -200,6 +174,39 @@ describe 'openstack_extras::repo::redhat::redhat' do
|
||||
)}
|
||||
end
|
||||
|
||||
context 'with epel management enabled' do
|
||||
let :params do
|
||||
default_params.merge!({ :manage_epel => true })
|
||||
end
|
||||
|
||||
# 'metalink' property is supported from Puppet 3.5
|
||||
if Puppet.version.to_f >= 3.5
|
||||
it { should contain_yumrepo('epel').with(
|
||||
:metalink => "https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=\$basearch",
|
||||
:descr => 'Extra Packages for Enterprise Linux 7 - $basearch',
|
||||
:gpgkey => 'file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7',
|
||||
:failovermethod => 'priority',
|
||||
:enabled => '1',
|
||||
:gpgcheck => '1',
|
||||
:mirrorlist => 'absent',
|
||||
:require => 'Anchor[openstack_extras_redhat]',
|
||||
:notify => 'Exec[yum_refresh]'
|
||||
)}
|
||||
else
|
||||
it { should contain_yumrepo('epel').with(
|
||||
:baseurl => "https://download.fedoraproject.org/pub/epel/7/\$basearch",
|
||||
:descr => 'Extra Packages for Enterprise Linux 7 - $basearch',
|
||||
:gpgkey => 'file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7',
|
||||
:failovermethod => 'priority',
|
||||
:enabled => '1',
|
||||
:gpgcheck => '1',
|
||||
:mirrorlist => 'absent',
|
||||
:require => 'Anchor[openstack_extras_redhat]',
|
||||
:notify => 'Exec[yum_refresh]'
|
||||
)}
|
||||
end
|
||||
end
|
||||
|
||||
context 'with epel management disabled' do
|
||||
let :params do
|
||||
default_params.merge!({ :manage_epel => false })
|
||||
|
Loading…
x
Reference in New Issue
Block a user