-
Notifications
You must be signed in to change notification settings - Fork 346
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
Implementation of ps commmand #172
Implementation of ps commmand #172
Conversation
deaf06b
to
850f54a
Compare
Hey, can you give an example of using this? |
issue: #146 like this: $ mkdir tutorial
$ cd tutorial
$ mkdir rootfs
$ docker export $(docker create busybox) | tar -C rootfs -xvf -
$ youki create youki-container # need to create container
$ youki ps youki-conainer
UID PID PPID C STIME TTY TIME CMD
root 4354 0 0 13:18 ? 00:00:00 youki create youki-container I have passed the test on my linux system, if there is any problem, please let me know. |
Interesting, I followed you instructions, and now it recognizes the container, but it gives an OS error when running the ps command :
Is there anything else needs to be done, in terms of permissions etc? I am also running linux system. |
Does the "/sys/fs/cgroup/devices/youki/youki-container" folder exist? I checked it through the path mounted by cgroups. I don't have a linux system to try now, because I am working with macos. I will try again later. |
It looks like you created a rootless container, but I don't know how to create a rootless container.
how to set the uid mapping? @YJDoc2 |
This is very interesting, as now when I try I get the same error, but I'm sure that at the time of my last comment, I was running without root access, and the create command was working 🤔 🤔 |
No, I think It may be a hidden bug. The "/tmp/rootless/youki-container" folder exists, but "/sys/fs/cgroup/devices/youki/youki-container" folder does not exist. This should be a bug of create command. |
@zidoshare The reason it does not work for rootless containers is that creating cgroups is not yet supported. The implementation is ongoing at #120. I will take a look at this soon, no need to investigate further for now. |
Well, my code should be correct, I am sure 😆 |
@zidoshare Looks good. Please resolve the merge conflicts, then I will approve. |
ea6f5f7
to
7d52b3f
Compare
7d52b3f
to
1398da8
Compare
@Furisto resolved.
|
Thanks @zidoshare |
hello, I added the implementation of the ps command.
However, there is a small problem at present, I have not found a way to remove ”--“.
Currently, only the ps option can be added after ”--“. like this:
Does it need to be implemented like runc?