Code Review
/
puppet-modules
/
puppetlabs-apt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
(MODULES-7153) - Unmanage gitlab-ci.yml
[puppet-modules/puppetlabs-apt.git]
/
manifests
/
source.pp
diff --git
a/manifests/source.pp
b/manifests/source.pp
index 3e6d0cb814870d0b30a4b3bd0fab11282d4e3935..670b83035864108a7d28932678dc27287c394dab 100644
(file)
--- a/
manifests/source.pp
+++ b/
manifests/source.pp
@@
-29,10
+29,13
@@
define apt::source(
$_release = $release
}
$_release = $release
}
+ # Some releases do not support https transport with default installation
+ $_transport_https_releases = [ 'wheezy', 'jessie', 'stretch', 'trusty', 'xenial' ]
+
if $ensure == 'present' {
if ! $location {
fail('cannot create a source entry without specifying a location')
if $ensure == 'present' {
if ! $location {
fail('cannot create a source entry without specifying a location')
- } elsif $_release
== 'jessie'
{
+ } elsif $_release
in $_transport_https_releases
{
$method = split($location, '[:\/]+')[0]
if $method == 'https' {
ensure_packages('apt-transport-https')
$method = split($location, '[:\/]+')[0]
if $method == 'https' {
ensure_packages('apt-transport-https')