Installing apps into containers

24 views
Skip to first unread message

Nidhal Ghanmi

unread,
Dec 6, 2021, 6:46:39 AM12/6/21
to singularity
Hello


I am willing on how to in order to install additional apps into a created or pulled container ?


I tryed with some options like
$ singularity --sandbox --update sandbox/ file.def
or
$ singularity shell --writable sandbox/

Everything will always look fine , and everything installed but later new tool or tools will never appear
$ singularity exec sandbox/ which tool-name
gives nothing


Please any proper way to do this ?

Thanks
Nidhal

Dave Dykstra

unread,
Dec 7, 2021, 10:25:43 AM12/7/21
to singu...@lbl.gov
Nidhal,

The --writable option does not allow saving changes in the container,
similar to a normal docker container. The best option is to build a
fresh container based on another one using the image build tools.
Otherwise I believe I did see a way to save changes once but I have
never used it and so don't know the details.

Dave
> --
> You received this message because you are subscribed to the Google Groups "singularity" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to singularity...@lbl.gov.
> To view this discussion on the web visit https://groups.google.com/a/lbl.gov/d/msgid/singularity/2cb5c565-0ebe-44c3-97b6-a66d7af7b9a4n%40lbl.gov .

David Godlove

unread,
Dec 7, 2021, 10:33:28 AM12/7/21
to singularity
You can save changes to a sandbox.  Use the --sandbox option with the build command.  This creates a plain old chroot directory for you instead of a sif.  These containers are rw if you use the --writable option with them and changes will persist.  But they are only appropriate for development.  Use a sif for production.  If you need changes to persist in your sif, use a directory or an ext3 image as writable overlay.  See this:


Reply all
Reply to author
Forward
0 new messages