Skip to content

Commit cec4b4e

Browse files
authored
Merge pull request #245 from inab/STABLE-1.0.x
Synchronise with stable 1.0.x
2 parents ca40f6e + 423dfa4 commit cec4b4e

1 file changed

Lines changed: 48 additions & 0 deletions

File tree

WFEXS-in-CONTAINERS.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,53 @@
11
# Running WfExS from within a container (alpha/beta)!
22

3+
## Singularity/Apptainer setup details to take into account
4+
5+
First, as it is described at https://github.com/sylabs/singularity/blob/de57924bf0c0bb922623aa0d3259a5f40ee68b59/INSTALL.md#apparmor-profile-ubuntu-2404
6+
Linux distributions with apparmor enabled by default (like Ubuntu 24.04 LTS and later) usually
7+
do not permit applications to create unprivileged user namespaces by default.
8+
9+
Unprivileged user namespaces **is** the feature which makes Singularity
10+
and Apptainer possible.
11+
12+
* If you install either SingularityCE or Apptainer from a GitHub release
13+
`.deb` package then any of them installs an apparmor profile that permits
14+
to create unprivileged user namespaces.
15+
16+
* If you install either SingularityCE or Apptainer from source, then you need
17+
to create as administrator an apparmor profile file pointing out to the right path,
18+
and putting the file into the `/etc/apparmor.d` directory. It should be something like:
19+
20+
```
21+
# Permit unprivileged user namespace creation for SingularityCE starter
22+
# assuming it was installed under /usr/local
23+
abi <abi/4.0>,
24+
include <tunables/global>
25+
26+
profile singularity-ce /usr/local/libexec/singularity/bin/starter{,-suid} flags=(unconfined) {
27+
userns,
28+
29+
# Site-specific additions and overrides.
30+
include if exists <local/singularity-ce>
31+
}
32+
```
33+
34+
or
35+
36+
```
37+
# Permit unprivileged user namespace creation for Apptainer starter
38+
# assuming it was installed under /usr/local
39+
abi <abi/4.0>,
40+
include <tunables/global>
41+
42+
profile apptainer /usr/local/libexec/apptainer/bin/starter{,-suid} flags=(unconfined) {
43+
userns,
44+
45+
# Site-specific additions and overrides.
46+
include if exists <local/apptainer>
47+
}
48+
EOF
49+
```
50+
351
## Singularity/Apptainer within Singularity/Apptainer (works also for encrypted workdirs)
452

553
For this approach we have been using both `-e` and `-c` parameters from Singularity/Apptainer. It is also possible to use `-u`.

0 commit comments

Comments
 (0)