gvisor icon indicating copy to clipboard operation
gvisor copied to clipboard

From source build runsc with Podman not Docker

Open unknowndevQwQ opened this issue 5 years ago • 5 comments

Description

Is there any way to build runsc with Podman instead of Docker?

unknowndevQwQ avatar Dec 28 '20 11:12 unknowndevQwQ

There is nothing specific to Docker in runsc. Both Podman and Docker create containers using a common interface: OCI runtime interface. This interface is implemented by runC to create containers as processes in Linux. While runsc implements it by creating containers inside a gVisor sandbox. I don't have experience with Podman, but as long as Podman complies to the runtime interface, runsc will work. I found some information below about how to configure Podman to use different runtimes:

https://manpages.debian.org/unstable/podman/libpod.conf.5.en.html https://serverfault.com/questions/989509/how-can-i-change-the-oci-runtime-in-podman

Please give it a try and feel free to create more issues if anything doesn't work.

fvoznika avatar Jan 05 '21 23:01 fvoznika

I know how to use gvisor in podman, but I'm talking about whether docker in https://github.com/google/gvisor#installing-from-source can be replaced by podman, and if not, is it considered to add support in the future?

I need to compile from source because I want to try to package gVisor from source and pass all the tests, but since docker will break my network environment I try to use podman

unknowndevQwQ avatar Feb 17 '21 14:02 unknowndevQwQ

I see what you mean now. You can build using Bazel directly, e.g. bazel build runsc. Or you set DOCKER_BUILD=false if you'd like to continue to use make. You could look into making docker/podman configurable in bazel.mk.

fvoznika avatar Feb 23 '21 18:02 fvoznika

Could you please reopen this issue? I can't solve this problem at the moments.

unknowndevQwQ avatar Apr 15 '21 10:04 unknowndevQwQ

Why you need passthrough options when building from source with docker https://github.com/google/gvisor/blob/master/tools/bazel.mk#L112

unknowndevQwQ avatar Jul 25 '21 10:07 unknowndevQwQ