18113: Merge branch 'main' into 18113-change-cloudops-defaults
[arvados.git] / doc / install / singularity.html.textile.liquid
1 ---
2 layout: default
3 navsection: installguide
4 title: Singularity container runtime
5 ...
6 {% comment %}
7 Copyright (C) The Arvados Authors. All rights reserved.
8
9 SPDX-License-Identifier: CC-BY-SA-3.0
10 {% endcomment %}
11
12 h2(#overview). Overview
13
14 Arvados can be configured to use "Singularity":https://sylabs.io/singularity/ instead of Docker to execute containers on cloud nodes or a SLURM/LSF cluster. Singularity may be preferable due to its simpler installation and lack of long-running daemon process and special system users/groups.
15
16 *Current limitations*:
17 * Even when using the singularity runtime, users' container images are expected to be saved in Docker format using @arv keep docker@. Arvados converts the Docker image to Singularity format (@.sif@) at runtime as needed. Specifying a @.sif@ file as an image when submitting a container request is not yet supported.
18 * Singularity does not limit the amount of memory available in a container. Each container will have access to all memory on the host where it runs, unless memory use is restricted by SLURM/LSF.
19 * Programs running in containers may behave differently due to differences between Singularity and Docker.
20 ** The root (image) filesystem is read-only in a Singularity container. Programs that attempt to write outside a designated output or temporary directory are likely to fail.
21 ** The Docker ENTRYPOINT instruction is ignored.
22 * Arvados is tested with Singularity version 3.7.4. Other versions may not work.
23
24 h2(#configuration). Configuration
25
26 To use singularity, first make sure "Singularity is installed":https://sylabs.io/guides/3.7/user-guide/quick_start.html on your cloud worker image or SLURM/LSF compute nodes as applicable. Note @squashfs-tools@ is required.
27
28 <notextile>
29 <pre><code>$ <span class="userinput">singularity version</span>
30 3.7.4
31 $ <span class="userinput">mksquashfs -version</span>
32 mksquashfs version 4.3-git (2014/06/09)
33 [...]
34 </code></pre>
35 </notextile>
36
37 Then update @Containers.RuntimeEngine@ in your cluster configuration:
38
39 <notextile>
40 <pre><code>      # Container runtime: "docker" (default) or "singularity"
41       RuntimeEngine: singularity
42 </code></pre>
43 </notextile>
44
45 Restart your dispatcher (@crunch-dispatch-slurm@, @arvados-dispatch-cloud@, or @arvados-dispatch-lsf@) after updating your configuration file.