File tree 1 file changed +12
-0
lines changed
1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change
1
+ > [ !IMPORTANT]
1
2
> We take OpenFOAM as an example here, but containers for any other HPC software
2
3
> package can be built in the same way.
3
4
@@ -106,6 +107,17 @@ From: {{ CONTAINERS_DIR }}/basic/{{ BASE_CONTAINER }}.sif
106
107
107
108
# # Best practices for container usage
108
109
110
+ > [!TIP]
111
+ > The default containers are designed to run in an as-is state, only writing to your home folder.
112
+ > If you need to constantly change stuff in `/opt` for example inside the container, you have
113
+ > to create an overlay image and load it with the container when running it:
114
+ > ```bash
115
+ > apptainer overlay create --size 1024 overlay.img
116
+ > apptainer run --overlay overlay.img <your-container>.sif
117
+ > ```
118
+ > This is useful for example if you want to continuously develop on the container. Learn more
119
+ > about [Persistent Overlays](https://apptainer.org/docs/user/latest/persistent_overlays.html)
120
+
109
121
` ` ` bash
110
122
# Note the quoting of the command for openfoam-based containers (since it is fed to Bash as-is)
111
123
apptainer run containers/projects/test-master.sif "jq '.' /apps.json"
You can’t perform that action at this time.
0 commit comments