The proposal is to enable singularity to be able to push and pull images from an OCI compatible registry. Azure Container Registry an AWS's ECR already support the OCI specification. This is based off - https://github.com/stevelasker/registryArtifactTypes/
If we have native support for SIF as OCI then the experience could be something like this
# Creates a manifest and moves the file to a cache or location that singularity is comfortable with.
singularity build oci://hpccontainers.azurecr.io/singularity:centos -f ./layer_centos.sif
## Reference the local manifest which has the layer referenced from the layer cache.
singularity push oci://hpccontainers.azurecr.io/singularity:centos -u username -p password.
#Pulling and image extracts the manifes and file to the layer cache.
singularity pull oci://hpccontainers.azurecr.io/singularity:centos
# Running a locally cached oci image.
singularity run oci://hpccontainers.azurecr.io/singularity:centos
Today to demostrate this we can use oras to push and pull images. We don't have a manifest/repository cache and we might have to introduce some capabilities like providing oras a download root directory and also ask it to save manifest as well.
singularity pull library://verma/default/layer:centos
oras push sajayeus.azurecr.io/singularity:centos ./layer_centos.sif -u sajayeus -p $PASSWORD
oras pull sajayeus.azurecr.io/singularity:centos -u sajayeus -p $PASSWORD
singularity run ./layer_centos.sif