2018-01-12 12:43:07 +01:00
|
|
|
# singularity
|
|
|
|
|
|
|
|
> Manage Singularity containers and images.
|
2022-07-27 13:38:46 +02:00
|
|
|
> More information: <https://singularity-docs.readthedocs.io/en/latest/#commands>.
|
2018-01-12 12:43:07 +01:00
|
|
|
|
2019-09-16 09:35:23 +02:00
|
|
|
- Download a remote image from Sylabs Cloud:
|
2018-01-12 12:43:07 +01:00
|
|
|
|
2019-09-16 09:35:23 +02:00
|
|
|
`singularity pull --name {{image.sif}} {{library://godlovedc/funny/lolcow:latest}}`
|
2018-01-12 12:43:07 +01:00
|
|
|
|
2021-08-15 19:59:09 +02:00
|
|
|
- Rebuild a remote image using the latest Singularity image format:
|
2018-01-12 12:43:07 +01:00
|
|
|
|
2019-09-16 09:35:23 +02:00
|
|
|
`singularity build {{image.sif}} {{docker://godlovedc/lolcow}}`
|
2018-01-12 12:43:07 +01:00
|
|
|
|
2021-08-15 19:59:09 +02:00
|
|
|
- Start a container from an image and get a shell inside it:
|
2018-01-12 12:43:07 +01:00
|
|
|
|
2019-09-16 09:35:23 +02:00
|
|
|
`singularity shell {{image.sif}}`
|
2018-01-12 12:43:07 +01:00
|
|
|
|
|
|
|
- Start a container from an image and run a command:
|
|
|
|
|
2019-09-16 09:35:23 +02:00
|
|
|
`singularity exec {{image.sif}} {{command}}`
|
2018-01-12 12:43:07 +01:00
|
|
|
|
|
|
|
- Start a container from an image and execute the internal runscript:
|
|
|
|
|
2019-09-16 09:35:23 +02:00
|
|
|
`singularity run {{image.sif}}`
|
2018-01-12 12:43:07 +01:00
|
|
|
|
|
|
|
- Build a singularity image from a recipe file:
|
|
|
|
|
2019-09-16 09:35:23 +02:00
|
|
|
`sudo singularity build {{image.sif}} {{recipe}}`
|