Apptainer cache location

I was trying to figure out where [Apptainer][apptainer] caches images in its SIF format created on the fly from OCI images pulled from a remote registry. The location appears to be under ~/.apptainer/cache/oci-tmp/, as can be seen if you explicitly convert a Docker image to a SIF file at a known path (here ~/somefile.sif) then search for another file with the same checksum under ~/.apptainer: [someuser@node001 [stanage] ~]$ apptainer run docker://alpine:latest whoami INFO: Using cached SIF image someuser [someuser@node001 [stanage] ~]$ apptainer pull somefile.

Apptainer cache validity

I was recently asked whether Apptainer (forked from the Singularity project) will definitely update its cache of Apptainer images created from OCI/Docker images if a tagged image changes on a remote repo. Let’s find out: Let’s start by creating a v. simple image that just sends a message to stdout when executed. After creating the image we tag it so we have an identifier to push to a remote image registry.

All content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA-4.0).