|
96 | 96 | when '8' |
97 | 97 | it { |
98 | 98 | is_expected.to contain_yumrepo('cvmfs'). |
99 | | - with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/EL/8/x86_64'). |
| 99 | + with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/EL/8/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs/EL/8/x86_64'). |
100 | 100 | with_gpgkey('https://cvmrepo.s3.cern.ch/cvmrepo/yum/RPM-GPG-KEY-CernVM') |
101 | 101 | } |
102 | 102 |
|
103 | | - it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/EL/8/x86_64') } |
104 | | - it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/EL/8/x86_64') } |
| 103 | + it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/EL/8/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-testing/EL/8/x86_64') } |
| 104 | + it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/EL/8/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-config/EL/8/x86_64') } |
105 | 105 | when '9' |
106 | 106 | it { |
107 | 107 | is_expected.to contain_yumrepo('cvmfs'). |
108 | | - with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/EL/9/x86_64'). |
| 108 | + with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/EL/9/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs/EL/9/x86_64'). |
109 | 109 | with_gpgkey('https://cvmrepo.s3.cern.ch/cvmrepo/yum/RPM-GPG-KEY-CernVM') |
110 | 110 | } |
111 | 111 |
|
112 | | - it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/EL/9/x86_64') } |
113 | | - it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/EL/9/x86_64') } |
| 112 | + it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/EL/9/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-testing/EL/9/x86_64') } |
| 113 | + it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/EL/9/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-config/EL/9/x86_64') } |
114 | 114 | else |
115 | 115 | it { |
116 | 116 | is_expected.to contain_yumrepo('cvmfs'). |
117 | | - with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/EL/10/x86_64'). |
| 117 | + with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/EL/10/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs/EL/10/x86_64'). |
118 | 118 | with_gpgkey('https://cvmrepo.s3.cern.ch/cvmrepo/yum/RPM-GPG-KEY-CernVM-2048') |
119 | 119 | } |
120 | 120 |
|
121 | | - it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/EL/10/x86_64') } |
122 | | - it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/EL/10/x86_64') } |
| 121 | + it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/EL/10/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-testing/EL/10/x86_64') } |
| 122 | + it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/EL/10/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-config/EL/10/x86_64') } |
123 | 123 | end |
124 | 124 | it do |
125 | 125 | is_expected.to contain_yumrepo('cvmfs').with( |
|
152 | 152 | when 'Fedora' |
153 | 153 | case facts[:os]['release']['major'] |
154 | 154 | when '41' |
155 | | - it { is_expected.to contain_yumrepo('cvmfs').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/fedora/41/x86_64') } |
156 | | - it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/fedora/41/x86_64') } |
157 | | - it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/fedora/41/x86_64') } |
| 155 | + it { is_expected.to contain_yumrepo('cvmfs').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/fedora/41/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs/fedora/41/x86_64') } |
| 156 | + it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/fedora/41/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-testing/fedora/41/x86_64') } |
| 157 | + it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/fedora/41/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs-config/fedora/41/x86_64') } |
158 | 158 | else |
159 | | - it { is_expected.to contain_yumrepo('cvmfs').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/fedora/42/x86_64') } |
160 | | - it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/fedora/42/x86_64') } |
161 | | - it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/fedora/42/x86_64') } |
| 159 | + it { is_expected.to contain_yumrepo('cvmfs').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs/fedora/42/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs/fedora/42/x86_64') } |
| 160 | + it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-testing/fedora/42/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs/fedora/42/x86_64') } |
| 161 | + it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl('https://cvmrepo.s3.cern.ch/cvmrepo/yum/cvmfs-config/fedora/42/x86_64 https://cvmrepo.web.cern.ch/cvmrepo/yum/cvmfs/fedora/42/x86_64') } |
162 | 162 | end |
163 | 163 | else |
164 | 164 | case facts[:os]['distro']['codename'] |
|
260 | 260 | end |
261 | 261 | end |
262 | 262 |
|
263 | | - context 'with repo_base set to http://example.org/base' do |
| 263 | + context 'with repo_base set to a string http://example.org/base' do |
264 | 264 | let(:params) do |
265 | 265 | { repo_base: 'http://example.org/base', |
266 | 266 | cvmfs_http_proxy: :undef } |
|
277 | 277 | end |
278 | 278 | end |
279 | 279 |
|
| 280 | + context 'with repo_base set to array of size 1 [http://example.org/base]' do |
| 281 | + let(:params) do |
| 282 | + { repo_base: ['http://example.org/base'], |
| 283 | + cvmfs_http_proxy: :undef } |
| 284 | + end |
| 285 | + |
| 286 | + case facts[:os]['family'] |
| 287 | + when 'RedHat' |
| 288 | + it { is_expected.to contain_yumrepo('cvmfs').with_baseurl(%r{^http://example.org/base/cvmfs/(fedora|EL)/\d+/x86_64$}) } |
| 289 | + it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl(%r{^http://example.org/base/cvmfs-testing/(EL|fedora)/\d+/x86_64$}) } |
| 290 | + it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl(%r{^http://example.org/base/cvmfs-config/(EL|fedora)/\d+/x86_64$}) } |
| 291 | + else |
| 292 | + it { is_expected.to contain_apt__source('cvmfs').with_location('http://example.org/base') } |
| 293 | + it { is_expected.to contain_apt__source('cvmfs-testing').with_location('http://example.org/base') } |
| 294 | + end |
| 295 | + end |
| 296 | + |
| 297 | + context 'with repo_base set to an array of size 2 [http://example.org/base,http://example.net/base]' do |
| 298 | + let(:params) do |
| 299 | + { repo_base: ['http://example.org/base', 'http://example.net/base'], |
| 300 | + cvmfs_http_proxy: :undef } |
| 301 | + end |
| 302 | + |
| 303 | + case facts[:os]['family'] |
| 304 | + when 'RedHat' |
| 305 | + it { is_expected.to contain_yumrepo('cvmfs').with_baseurl(%r{^http://example.org/base/cvmfs/(fedora|EL)/\d+/x86_64 http://example.net/base/cvmfs/(fedora|EL)/\d+/x86_64$}) } |
| 306 | + it { is_expected.to contain_yumrepo('cvmfs-testing').with_baseurl(%r{^http://example.org/base/cvmfs-testing/(EL|fedora)/\d+/x86_64 http://example.net/base/cvmfs-testing/(EL|fedora)/\d+/x86_64$}) } |
| 307 | + it { is_expected.to contain_yumrepo('cvmfs-config').with_baseurl(%r{^http://example.org/base/cvmfs-config/(EL|fedora)/\d+/x86_64 http://example.net/base/cvmfs-config/(EL|fedora)/\d+/x86_64$}) } |
| 308 | + else |
| 309 | + it { is_expected.to compile.and_raise_error(%r{Debian family OSes only a single url}) } |
| 310 | + end |
| 311 | + end |
| 312 | + |
280 | 313 | context 'with cvmfs_quota_ratio set' do |
281 | 314 | let(:params) do |
282 | 315 | { cvmfs_quota_limit: 'auto', |
|
0 commit comments