apptainer-exec
Execute a command within an Apptainer container. tldr-pages
On Linux
Linux
Execute a command inside a container
apptainer exec path/to/image.sif commandIdentifyExecute a command with arguments
apptainer exec path/to/image.sif command arg1 arg2 ...IdentifyExecute a command with a bind mount from host to container
apptainer exec --bind path/to/source:path/to/destination path/to/image.sif commandIdentifyExecute a command with environment variables
apptainer exec --env variable=value path/to/image.sif commandIdentifyExecute a command in fully isolated mode (contained filesystem, PID, IPC, and clean environment)
apptainer exec --containall path/to/image.sif commandIdentifyExecute a command with a writable temporary filesystem overlay
apptainer exec --writable-tmpfs path/to/image.sif commandIdentifyExecute a command with NVIDIA GPU support
apptainer exec --nv path/to/image.sif commandIdentifyDisplay help
apptainer exec --helpIdentify