qemu
qemu copied to clipboard
Docker-in-docker (dind) under QEMU emulation
Allows docker:dind to run under QEMU emulation. Can run "docker run hello-world" with this set of changes.
docker run --privileged --platform linux/arm64 -t -i -v $(pwd)/cpuinfo-aarch64.txt:/proc/cpuinfo docker:dind --ip-masq=false --iptables=false --bridge=none
Pull in Tibor's changes.
- [ ] tibor - fix CSIGNAL andling in clone()
- [ ] tibor - implement pivot_root syscall
- [ ] tibor - implement pass-through fcntl for F_ADD_SEALS/F_GET_SEALS
- [ ] tibor - linux-user: implementations of (yolo) copy_file_range and keyctl
- [ ] tibor - handle execve of /proc/self/exe assuming binfmt P option
Add the following:
- [ ] tim - more error checking of /proc/self/cmdline handling of above
- [ ] tim - add CLONE_PARENT as allowed fork()
- [ ] tim - a complete hack to fake out runc's expectation of memfd and seals.
Todo:
- [ ] proper implementation of fcntl F_GET_SEALS
- [ ] proper implementation of copy_file_range
- [ ] only tested aarch64. Should probably check the other architectures including arm.
@tiborvass have you tried to upstream these fixes?
@tiborvass have you tried to upstream these fixes?
I've pointed out Tibor's last PR to Jason. My intent was to at least consolidate them into a branch and can figure out the upstream strategy later. Some are obviously not ready for upstream at the moment.
@tuonga I tried this step
docker run --privileged --platform linux/arm64 -t -i -v $(pwd)/cpuinfo-aarch64.txt:/proc/cpuinfo docker:dind --ip-masq=false --iptables=false --bridge=none
to get dind up on arm with amd host but I get this error while pulling images.
/ # docker pull hello-world
Using default tag: latest
latest: Pulling from library/hello-world
256ab8fe8778: Extracting [==================================================>] 3.367kB/3.367kB
failed to register layer: Error processing tar file(exit status 1):
Any inputs on this?
@rajaskakodkar Unfortunately I haven't worked on this project in a long time and am no longer with Docker. Perhaps @justincormack can point you in the right direction.
FWIW I've hit a similar error to you @rajaskakodkar and now I'm stuck:
failed to register layer: Error processing tar file(exit status 1):
Did you find a way to get past this issue?
Hello @vladaionescu, no, I don't have a fix for the issue, I am still stuck.
https://patchwork.kernel.org/project/qemu-devel/list/?series=490897&archive=both