Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

runtime: Ambiguous namespace for state pid and bundle #731

Open
wking opened this issue Mar 16, 2017 · 2 comments
Open

runtime: Ambiguous namespace for state pid and bundle #731

wking opened this issue Mar 16, 2017 · 2 comments

Comments

@wking
Copy link
Contributor

wking commented Mar 16, 2017

The spec has:

  • pid (int, REQUIRED when status is created or running) is the ID of the container process, as seen by the host.
  • bundle (string, REQUIRED) is the absolute path to the container's bundle directory.

I'm assuming those are both “in the runtime namespace”. However the “runtime namespace” wording needs to be tightened up in this case, because create and state may have been called from different namespaces. Is the pid value always in the create runtime namespace? Or when state is called from another PID namespace, is the container process ID translated into that PID namespace (if it is even visible)? The same ambiguity applies to bundle and mount namespaces.

I'd raised this issue on dev@ a while back, but with 1.0 approaching (#726), and dev@-based discussions being pretty quiet, I thought I'd cross-post here in case that helps with triage/prioritization.

@cyphar
Copy link
Member

cyphar commented Mar 16, 2017

I had some discussion about possibilities of how a runtime could implement namespace-agnostic ways. opencontainers/runc#1224. I'm not sure if it makes sense to define this in the spec, but it's an interesting idea IMO.

Maybe if we make state return a path to a procfs directory which users can then read stat and other pseudo-files to parse. Of course, this will massively break VM-based runtimes so it's probably not the best idea in the world.

@wking
Copy link
Contributor Author

wking commented Mar 16, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants