From abac810b968df8d7345023cb3a08b8788dacfd49 Mon Sep 17 00:00:00 2001 From: Wen Yang Date: Wed, 19 Aug 2020 19:47:03 +0800 Subject: [PATCH] basic/virt: treat "pouch" as a container type (id: pouch) --- man/systemd-detect-virt.xml | 5 +++++ man/systemd.unit.xml | 1 + src/basic/virt.c | 2 ++ src/basic/virt.h | 1 + 4 files changed, 9 insertions(+) diff --git a/man/systemd-detect-virt.xml b/man/systemd-detect-virt.xml index 24cbe9b368..ac5ffa5645 100644 --- a/man/systemd-detect-virt.xml +++ b/man/systemd-detect-virt.xml @@ -172,6 +172,11 @@ proot proot userspace chroot/bind mount emulation + + + pouch + Pouch Container Engine + diff --git a/man/systemd.unit.xml b/man/systemd.unit.xml index b3deb28956..7ef6080237 100644 --- a/man/systemd.unit.xml +++ b/man/systemd.unit.xml @@ -1169,6 +1169,7 @@ rkt, wsl, proot, + pouch, acrn to test against a specific implementation, or private-users to check whether we are running in a user namespace. See diff --git a/src/basic/virt.c b/src/basic/virt.c index c6bff6b16e..4c2280cfd6 100644 --- a/src/basic/virt.c +++ b/src/basic/virt.c @@ -442,6 +442,7 @@ static const char *const container_table[_VIRTUALIZATION_MAX] = { [VIRTUALIZATION_RKT] = "rkt", [VIRTUALIZATION_WSL] = "wsl", [VIRTUALIZATION_PROOT] = "proot", + [VIRTUALIZATION_POUCH] = "pouch", }; DEFINE_PRIVATE_STRING_TABLE_LOOKUP_FROM_STRING(container, int); @@ -679,6 +680,7 @@ static const char *const virtualization_table[_VIRTUALIZATION_MAX] = { [VIRTUALIZATION_RKT] = "rkt", [VIRTUALIZATION_WSL] = "wsl", [VIRTUALIZATION_PROOT] = "proot", + [VIRTUALIZATION_POUCH] = "pouch", [VIRTUALIZATION_CONTAINER_OTHER] = "container-other", }; diff --git a/src/basic/virt.h b/src/basic/virt.h index d58c582c91..18aa5eff15 100644 --- a/src/basic/virt.h +++ b/src/basic/virt.h @@ -35,6 +35,7 @@ enum { VIRTUALIZATION_RKT, VIRTUALIZATION_WSL, VIRTUALIZATION_PROOT, + VIRTUALIZATION_POUCH, VIRTUALIZATION_CONTAINER_OTHER, VIRTUALIZATION_CONTAINER_LAST = VIRTUALIZATION_CONTAINER_OTHER, -- 2.25.1