fail('lsbdistcodename fact not available: release parameter required')
}
- if $::apt::distid != 'ubuntu' {
- fail('apt::ppa is currently supported on Ubuntu and LinuxMint only.')
+ if $::apt::xfacts['lsbdistid'] == 'Debian' {
+ fail('apt::ppa is not currently supported on Debian.')
}
$filename_without_slashes = regsubst($name, '/', '-', 'G')
$filename_without_dots = regsubst($filename_without_slashes, '\.', '_', 'G')
- $filename_without_ppa = regsubst($filename_without_dots, '^ppa:', '', 'G')
+ $filename_without_pluses = regsubst($filename_without_dots, '\+', '_', 'G')
+ $filename_without_ppa = regsubst($filename_without_pluses, '^ppa:', '', 'G')
$sources_list_d_filename = "${filename_without_ppa}-${release}.list"
if $ensure == 'present' {
$_proxy = $::apt::_proxy
if $_proxy['host'] {
if $_proxy['https'] {
- $_proxy_env = ["http_proxy=http://${_proxy['host']}:${_proxy['port']}", "https_proxy=https://${_proxy['host']}:${_proxy['port']}"]
+ $_proxy_env = ["http_proxy=http://${$_proxy['host']}:${$_proxy['port']}", "https_proxy=https://${$_proxy['host']}:${$_proxy['port']}"]
} else {
- $_proxy_env = ["http_proxy=http://${_proxy['host']}:${_proxy['port']}"]
+ $_proxy_env = ["http_proxy=http://${$_proxy['host']}:${$_proxy['port']}"]
}
} else {
$_proxy_env = []
unless => "/usr/bin/test -s ${::apt::sources_list_d}/${sources_list_d_filename}",
user => 'root',
logoutput => 'on_failure',
- notify => Exec['apt_update'],
+ notify => Class['apt::update'],
require => $_require,
}
else {
file { "${::apt::sources_list_d}/${sources_list_d_filename}":
ensure => 'absent',
- notify => Exec['apt_update'],
+ notify => Class['apt::update'],
}
}
}