Closed n0rad closed 7 years ago
I cannot find a way during the build to get manifests of dependencies.
Nothing in /var/lib/rkt/pods/run/{id}/ have the dependencies manifest.
I thought about parsing mount
to find the /var/lib/rkt/cas/tree, but it does not seems to be a simple overlay.
@alban do you have a clue how I can find labels of a dependency from the stage1 ?
@sgotti: maybe you have an idea for the question above? dgr uses their own stage1 for building ACIs (see e.g. here). If the builder has access to CAS database (/var/lib/rkt/cas/db/ql.db), is it possible to find which version of dependencies a rendered tree was build from?
I commented on https://github.com/coreos/rkt/issues/2491#issuecomment-235330900
Is your need to have the manifests of all the dependencies used to render a specific image?
If you have access to the store you can just use acirenderer to get the dependency tree. This will work if dependencies in the image store aren't changed between preparing the pod an getting the dependency tree from acirenderer.
@sgotti The problem I'm trying to solve is that if the version of a dependency is not fixed, when you push it to a production server it will download it once, and then will never update it.
I could use --no-store but it will re-download all the aci/dependencies of the pod at each run (around 10 for our regular pods. More than 1Gb for some pods).
it's linked to https://github.com/coreos/rkt/issues/2276, but since it's not fixed yet, I was thinking about discovering the version during the build.
To define the version I need the complete list of labels so I need the manifest of the dependency.
I could use acirenderer, but It will not be safe in a CI environment where concurrent builds occurs.
done in v88 by :
pull-policy=update
and rely on Etag to not download up to date aci
aci's dependencies labels are not fixed if dependency info is not fixed.
During build, we can get all labels used from dependency and fix it in final pod's aci