Skip to content

Commit 77e7fc5

Browse files
committed
Fix Debian repo path, package GPG key ID for releases >=6
1 parent d10dd58 commit 77e7fc5

File tree

2 files changed

+21
-14
lines changed

2 files changed

+21
-14
lines changed

manifests/repo/apt.pp

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,14 @@
3131
include 'apt'
3232

3333
$repo_key_name = $release ? {
34-
'3.10' => 'C784DD0FD61E38B8B1F65E10DAD761554A72C1DF',
35-
'3.11' => 'DE82F0BACC4DB70DBEF95CA65EC2255642304A6E',
36-
'3.12' => '8B7C364430B66F0B084C0B0C55339A4C6A7BD8D4',
37-
'3.13' => '9B5AE8E6FD2581F293104ACC38675E5F30F779AF',
38-
'4.0' => '55F839E173AC06F364120D46FA86EEACB306CEE1',
39-
'4.1' => 'EED3351AFD72E5437C050F0388F6CDEE78FA6D97',
40-
'^5\.(\d)+$' => 'F9C958A3AEE0D2184FAD1CBD43607F0DC2F8238C',
41-
default => '849512C2CA648EF425048F55C883F50CB2289A17',
34+
'3.9' => '849512C2CA648EF425048F55C883F50CB2289A17',
35+
'3.10' => 'C784DD0FD61E38B8B1F65E10DAD761554A72C1DF',
36+
'3.11' => 'DE82F0BACC4DB70DBEF95CA65EC2255642304A6E',
37+
'3.12' => '8B7C364430B66F0B084C0B0C55339A4C6A7BD8D4',
38+
'3.13' => '9B5AE8E6FD2581F293104ACC38675E5F30F779AF',
39+
'4.0' => '55F839E173AC06F364120D46FA86EEACB306CEE1',
40+
'4.1' => 'EED3351AFD72E5437C050F0388F6CDEE78FA6D97',
41+
default => 'F9C958A3AEE0D2184FAD1CBD43607F0DC2F8238C',
4242
}
4343

4444
$repo_key_source = "https://download.gluster.org/pub/gluster/glusterfs/${release}/rsa.pub"
@@ -64,10 +64,17 @@
6464
'arm64' => 'arm64',
6565
default => false,
6666
}
67-
if versioncmp($release, '3.12') < 0 {
68-
$repo_url = "https://download.gluster.org/pub/gluster/glusterfs/${release}/LATEST/Debian/${::lsbdistcodename}/apt/"
67+
68+
$_repo_base = 'https://download.gluster.org/pub/gluster/glusterfs'
69+
$repo_url = if versioncmp($release, '4.1') < 0 {
70+
"${_repo_base}/01.old-releases/${release}/LATEST/Debian/${::lsbdistcodename}/${arch}/apt/"
6971
} else {
70-
$repo_url = "https://download.gluster.org/pub/gluster/glusterfs/${release}/LATEST/Debian/${::lsbdistcodename}/${arch}/apt/"
72+
$_release = if $release == '4.1' {
73+
$release
74+
} else {
75+
$release[0]
76+
}
77+
"${_repo_base}/${_release}/LATEST/Debian/${::lsbdistcodename}/${arch}/apt/"
7178
}
7279
}
7380
default: {

spec/classes/repo_apt_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
is_expected.to contain_apt__source('glusterfs-LATEST').with(
2020
repos: 'main',
2121
release: facts[:lsbdistcodename].to_s,
22-
location: "https://download.gluster.org/pub/gluster/glusterfs/3.12/LATEST/Debian/#{facts[:lsbdistcodename]}/#{facts[:architecture]}/apt/"
22+
location: "https://download.gluster.org/pub/gluster/glusterfs/7/LATEST/Debian/#{facts[:lsbdistcodename]}/#{facts[:architecture]}/apt/"
2323
)
2424
end
2525
end
@@ -47,7 +47,7 @@
4747
is_expected.to contain_apt__source('glusterfs-LATEST').with(
4848
repos: 'main',
4949
release: facts[:lsbdistcodename].to_s,
50-
location: "https://download.gluster.org/pub/gluster/glusterfs/3.12/LATEST/Debian/#{facts[:lsbdistcodename]}/#{facts[:architecture]}/apt/",
50+
location: "https://download.gluster.org/pub/gluster/glusterfs/7/LATEST/Debian/#{facts[:lsbdistcodename]}/#{facts[:architecture]}/apt/",
5151
pin: '700'
5252
)
5353
end
@@ -88,7 +88,7 @@
8888
'id' => '8B7C364430B66F0B084C0B0C55339A4C6A7BD8D4',
8989
'key_source' => 'https://download.gluster.org/pub/gluster/glusterfs/3.12/rsa.pub'
9090
},
91-
location: "https://download.gluster.org/pub/gluster/glusterfs/3.12/LATEST/Debian/#{facts[:lsbdistcodename]}/amd64/apt/"
91+
location: "https://download.gluster.org/pub/gluster/glusterfs/01.old-releases/3.12/LATEST/Debian/#{facts[:lsbdistcodename]}/amd64/apt/"
9292
)
9393
end
9494
end

0 commit comments

Comments
 (0)