mirror of
https://github.com/containers/podman.git
synced 2025-10-17 03:04:21 +08:00
libpod: Add FreeBSD support in packageVersion
This reports the correct package versions in 'podman info' for conmon and ociRuntime on FreeBSD which is needed for the 005-info system test. [NO NEW TESTS NEEDED] Signed-off-by: Doug Rabson <dfr@rabson.org>
This commit is contained in:
@ -171,11 +171,12 @@ func queryPackageVersion(cmdArg ...string) string {
|
|||||||
func packageVersion(program string) string { // program is full path
|
func packageVersion(program string) string { // program is full path
|
||||||
packagers := [][]string{
|
packagers := [][]string{
|
||||||
{"/usr/bin/rpm", "-q", "-f"},
|
{"/usr/bin/rpm", "-q", "-f"},
|
||||||
{"/usr/bin/dpkg", "-S"}, // Debian, Ubuntu
|
{"/usr/bin/dpkg", "-S"}, // Debian, Ubuntu
|
||||||
{"/usr/bin/pacman", "-Qo"}, // Arch
|
{"/usr/bin/pacman", "-Qo"}, // Arch
|
||||||
{"/usr/bin/qfile", "-qv"}, // Gentoo (quick)
|
{"/usr/bin/qfile", "-qv"}, // Gentoo (quick)
|
||||||
{"/usr/bin/equery", "b"}, // Gentoo (slow)
|
{"/usr/bin/equery", "b"}, // Gentoo (slow)
|
||||||
{"/sbin/apk", "info", "-W"}, // Alpine
|
{"/sbin/apk", "info", "-W"}, // Alpine
|
||||||
|
{"/usr/local/sbin/pkg", "which", "-q"}, // FreeBSD
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, cmd := range packagers {
|
for _, cmd := range packagers {
|
||||||
|
Reference in New Issue
Block a user