Skip to content

Commit bac8e1d

Browse files
committed
backports: don't hardcode an old gpg key for Ubuntu
Same as puppetlabs#847 but for Ubuntu. The gpg keys used to sign the Ubuntu repos, including backports, come with standard Ubuntu installations, so this Puppet module doesn't need to add any key. Having this old key causes Puppet run failures for 20.04 and newer machines without Internet access.
1 parent 513bbef commit bac8e1d

File tree

3 files changed

+2
-9
lines changed

3 files changed

+2
-9
lines changed

manifests/backports.pp

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,7 @@
6262
if $repos {
6363
$_repos = $repos
6464
}
65-
if $key {
66-
$_key = $key
67-
}
65+
6866
if (!($facts['os']['name'] == 'Debian' or $facts['os']['name'] == 'Ubuntu')) {
6967
unless $location and $release and $repos and $key {
7068
fail('If not on Debian or Ubuntu, you must explicitly pass location, release, repos, and key')
@@ -83,9 +81,6 @@
8381
unless $repos {
8482
$_repos = $apt::backports['repos']
8583
}
86-
unless $key {
87-
$_key = $apt::backports['key']
88-
}
8984

9085
if $pin =~ Hash {
9186
$_pin = $pin
@@ -105,7 +100,7 @@
105100
release => $_release,
106101
repos => $_repos,
107102
include => $include,
108-
key => $_key,
103+
key => $key,
109104
pin => $_pin,
110105
}
111106
}

manifests/params.pp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,6 @@
8888
'Ubuntu': {
8989
$backports = {
9090
'location' => 'http://archive.ubuntu.com/ubuntu',
91-
'key' => '630239CC130E1A7FD81A27B140976EAF437D05B5',
9291
'repos' => 'main universe multiverse restricted',
9392
}
9493
$ppa_options = ['-y']

spec/classes/apt_backports_spec.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@
5252

5353
it {
5454
expect(subject).to contain_apt__source('backports').with(location: 'http://archive.ubuntu.com/ubuntu',
55-
key: '630239CC130E1A7FD81A27B140976EAF437D05B5',
5655
repos: 'main universe multiverse restricted',
5756
release: 'bionac-backports',
5857
pin: { 'priority' => 200, 'release' => 'bionac-backports' })

0 commit comments

Comments
 (0)