fix: add unpack logic after container commit to images.#3268
fix: add unpack logic after container commit to images.#3268AkihiroSuda merged 1 commit intocontainerd:mainfrom
Conversation
|
test commands and results: nerdctl -n k8s.io commit 555dd4b423742 lingdie/commit:dev
WARN[0000] Image lacks label "nerdctl/platform", assuming the platform to be "linux/amd64"
sha256:55920a9d373f7778901f57501cf15cb5233f69ceadc38ceae827bc7404455643
nerdctl -n k8s.io inspect lingdie/commit:dev
[
{
"Id": "sha256:55920a9d373f7778901f57501cf15cb5233f69ceadc38ceae827bc7404455643",
"RepoTags": [
"lingdie/commit:dev"
],
"RepoDigests": [
"lingdie/commit@sha256:3684882f267f612a499de1786a627e216b8db0510fede8d817429606e64f546d"
],
"Parent": "",
"Comment": "",
"Created": "2024-08-01T08:07:58.833742114Z",
"DockerVersion": "",
"Author": "",
"Config": {
"AttachStdin": false,
"Env": [
"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
],
"Cmd": [
"/bin/bash"
],
"WorkingDir": "/root",
"Labels": {
"org.opencontainers.image.ref.name": "ubuntu",
"org.opencontainers.image.version": "24.04"
}
},
"Architecture": "amd64",
"Os": "linux",
"Size": 87519232,
"VirtualSize": 87519232,
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:a30a5965a4f7d9d5ff76a46eb8939f58e95be844de1ac4a4b452d5d31158fdea",
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
"sha256:97b66fcb143832ac7d953ff66d09c77c2ba31290d3aa422b2bc27762f55e0a73"
]
},
"Metadata": {
"LastTagTime": "0001-01-01T00:00:00Z"
}
}
]
nerdctl -n k8s.io push lingdie/commit:dev
INFO[0000] pushing as a reduced-platform image (application/vnd.docker.distribution.manifest.v2+json, sha256:3684882f267f612a499de1786a627e216b8db0510fede8d817429606e64f546d)
manifest-sha256:3684882f267f612a499de1786a627e216b8db0510fede8d817429606e64f546d: done |++++++++++++++++++++++++++++++++++++++|
config-sha256:55920a9d373f7778901f57501cf15cb5233f69ceadc38ceae827bc7404455643: done |++++++++++++++++++++++++++++++++++++++|
elapsed: 4.4 s total: 2.5 Ki (579.0 B/s) |
|
@lingdie you should DCO and sign your commits (git commit -s -S) to make project checks happy, and squash your commits. Now, this overall is reminiscent of #2327 . @fahedouch + @AkihiroSuda do you have a good intuition on this overall? |
Signed-off-by: yy <lingdie.yy@outlook.com>
|
It's not easy to add tests. The environment corresponding to the issue is to commit the pod container in k8s. I cannot create a test environment and test cases from the existing tests. It would be great if you could provide me with more information. And please rerun ci, some ci tests failed because of docker.io 502 error 😢... |
Ah! I recently cleaned-up that part in nydus, so, maybe we could reuse some of that stuff to spin-up our env:
I cannot do that, but @AkihiroSuda can :-). |
|
@lingdie now we can test for Kube. Here is an example: |
|
sudo /usr/local/bin/nerdctl -n k8s.io push kubesharkwork |
May fix this: #827