Linux containers on FreeBSD

This allows running Linux containers on FreeBSD and modifies the
mounts so that they represent the linux emulated filesystems, as per:
https://wiki.freebsd.org/LinuxJails

Co-authored-by: Gijs Peskens <gijs@peskens.net>, Samuel Karp <samuelkarp@users.noreply.github.com>
Signed-off-by: Artem Khramov <akhramov@pm.me>
This commit is contained in:
Gijs Peskens
2021-05-10 15:21:11 +00:00
committed by Artem Khramov
parent c76559a6a9
commit ae22854e2b
7 changed files with 124 additions and 2 deletions

View File

@@ -377,6 +377,7 @@ func WithImageConfigArgs(image Image, args []string) SpecOpts {
return fmt.Errorf("unknown image config media type %s", ic.MediaType)
}
appendOSMounts(s, ociimage.OS)
setProcess(s)
if s.Linux != nil {
defaults := config.Env