Get back container tools on Ubuntu 18&20 (#5611)

This commit is contained in:
Mikhail Timofeev
2022-05-25 20:25:12 +04:00
committed by GitHub
parent 102af04076
commit 4393b58dce
6 changed files with 38 additions and 9 deletions

View File

@@ -42,16 +42,28 @@ function Get-CodeQLBundleVersion {
function Get-PodManVersion {
$podmanVersion = podman --version | Take-OutputPart -Part 2
if ((Test-IsUbuntu18) -or (Test-IsUbuntu20)) {
$aptSourceRepo = Get-AptSourceRepository -PackageName "containers"
return "Podman $podmanVersion (apt source repository: $aptSourceRepo)"
}
return "Podman $podmanVersion"
}
function Get-BuildahVersion {
$buildahVersion = buildah --version | Take-OutputPart -Part 2
if ((Test-IsUbuntu18) -or (Test-IsUbuntu20)) {
$aptSourceRepo = Get-AptSourceRepository -PackageName "containers"
return "Buildah $buildahVersion (apt source repository: $aptSourceRepo)"
}
return "Buildah $buildahVersion"
}
function Get-SkopeoVersion {
$skopeoVersion = skopeo --version | Take-OutputPart -Part 2
if ((Test-IsUbuntu18) -or (Test-IsUbuntu20)) {
$aptSourceRepo = Get-AptSourceRepository -PackageName "containers"
return "Skopeo $skopeoVersion (apt source repository: $aptSourceRepo)"
}
return "Skopeo $skopeoVersion"
}