Skip to content

What is a container, really?

Select an icon to see what it is.

Step 5 of 6

It is just a process

On the host, ps shows nginx as an ordinary process with PID 4321. Inside the container the same process is PID 1, because of the pid namespace. Two views of one process.

$ docker top web

Same process, two views

host: 4321 nginx: master process nginx -g daemon off;
container: 1 nginx: master process nginx -g daemon off;
/proc/4321/ns/pid -> pid:[<inode>]