piggy-back on apptainer SIF image cache #143
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This resolves #141 for
apptainer
but not the other singularity flavors.apptainer
has an in-container environment variableAPPTAINER_CONTAINER
that holds the full path to the SIF image that was used to launch the container.1 This environment variable is not documented, but is exactly what we want since it allows us to useapptainer
to cache a local copy of the SIF image built from an OCI image and then we just launch it to retrieve the path to this cached image.The other singularity flavors are supported as before, manually building the SIF image ourselves, meaning different denvs must have their own copy of the image even if the two are identical and owned by the same user.
Leaving this as draft in order to
denv
docs.denv
supports running from a manually built SIF image as well, so if users are preparing a cluster-wide processing campaign, they should manually build and fix a SIF that they can then providedenv
.Footnotes
https://github.com/apptainer/apptainer/blob/e6fc6f0d5862a372241a8bec50b980036e37975e/internal/pkg/runtime/launch/launcher_linux.go#L526 ↩