Closed estebanreyl closed 1 year ago
Have you tried converting the same image using a userspace converter without going through the container? Does it have the same problem? I think something may have gone wrong causing overlaybd-tools to not properly link our customized libe2fs when using it through a container.
I think it's the addition of the following sentence to # Copy Conversion Tools
that solves the problem.
COPY --from=overlaybd-build /opt/overlaybd/lib /opt/overlaybd/lib
I added the line as mentioned and things now work! I think that makes sense, if that is not included there is a fallback to the installed libe2fs which I suppose breaks reproducibility in this instance. I don't remember this being an issue before, but I realize it might be one moving forward. Ill open a little PR to note this detail on the user space convertor docs. https://github.com/containerd/accelerated-container-image/blob/main/docs/USERSPACE_CONVERTOR.md#libext2fs
Resolved
What happened in your environment?
I tried running the user space convertor from a container and I am noticing that the outputted layers for the same image are different every time. I have yet to verify if this happens for every image, but below is my repro using python:3.8 at least.
What did you expect to happen?
I expected converted layers for the same image to output identically between runs.
How can we reproduce it?
I made a simple script to aide with reproducibility which includes an image I am seeing this issue for and converts it four times then outputs the resulting descriptor. I am unclear yet if this happens for other images/why it occurs. The output will show the descriptor of the different images. I also output the manifests in the results folder for easier comparisons. (The script can be run as is with no extra parameters or changes)
The above script also requires the mariner.Dockerfile:
What is the version of your Accelerated Container Image?
accelerated-containers: 5a4b6635df9cf8aa5eb986b718224edf1f598cf7 (latest as of 7/19/2023) overlaybd: 4eee2a3b590a6a25b19f331cf17c3b5a1051befc (latest as of 7/19/2023)
What is your OS environment?
Mariner (Docker Container)
Are you willing to submit PRs to fix it?