It's difficult to encode the json with special characters such as '"', '>'...
encoding and unicoding these characters will change the length of json message,
it's a pain to get bytes contains these characters from json.
This patch allows to read the bytes contains special character outside the json.
for example:
{"container":"c5f67934326d2ecef59fee62148bc9237e2481cd803cc0760a6406da15f4ee60","file":"/tmp/aaa"}sssssss
Signed-off-by: Gao feng <omarapazanadi@gmail.com>
manpage of setns says:
>CLONE_NEWPID behaves somewhat differently from the other nstype values: reassociating the calling thread with a PID namespace changes only the PID namespace that child processes of the caller will
>be created in; it does not change the PID namespace of the caller itself. Reassociating with a PID namespace is allowed only if the PID namespace specified by fd is a descendant (child, grandchild,
>etc.) of the PID namespace of the caller. For further details on PID namespaces, see pid_namespaces(7).
so clone a temporary process to enter pid ns, and then create containers. and join them to the other nss of pod init.
Signed-off-by: Gao feng <omarapazanadi@gmail.com>
The files under src directory is the codes of hyperStart,
use autogen.sh && configure && make to generate hyper-initrd.img,
this image will be used to start hyper instance.
Signed-off-by: Gao feng <feng@hyper.sh>