Commit ea952f8d authored by Jan Siwiec's avatar Jan Siwiec

Update easybuild-images.md

parent 9fe9964e
Pipeline #11298 passed with stages
in 23 minutes and 37 seconds
......@@ -4,13 +4,13 @@ EasyBuild has support for generating container recipes that will use EasyBuild t
!!! info
The features documented here have been available since **EasyBuild v3.6.0** but are still experimental, which implies they are subject to change in upcoming versions of EasyBuild.
You will need to enable the `--experimental` configuration option in order to use them.
To use the features, enable the `--experimental` configuration option.
## Generating Container Recipes
To generate container recipes, use `eb --containerize`, or `eb -C` for short.
The resulting container recipe will, in turn, leverage EasyBuild to build and install the software that corresponds to the easyconfig files that are specified as arguments to the eb command (and all required dependencies, if needed).
The resulting container recipe will leverage EasyBuild to build and install the software that corresponds to the easyconfig files that are specified as arguments to the eb command (and all required dependencies, if needed).
!!! note
EasyBuild will refuse to overwrite existing container recipes.
......@@ -46,7 +46,7 @@ To let EasyBuild generate a container recipe for GCC 6.4.0 + binutils 2.28:
eb GCC-6.4.0-2.28.eb --containerize --container-base localimage:/tmp/example.simg --experimental
```
With other configuration options left to default (see output of `eb --show-config`), this will result in a Singularity container recipe using example.simg as base image, which will be stored in `$HOME/.local/easybuild/containers`:
With other configuration options left to default (see the output of `eb --show-config`), this will result in a Singularity container recipe using example.simg as a base image, which will be stored in `$HOME/.local/easybuild/containers`:
```console
$ eb GCC-6.4.0-2.28.eb --containerize --container-base localimage:/tmp/example.simg --experimental
......@@ -58,7 +58,7 @@ $ eb GCC-6.4.0-2.28.eb --containerize --container-base localimage:/tmp/example.s
## Example of a Generated Container Recipe
Below is an example of container recipe for that was generated by EasyBuild, using the following command:
Below is an example of container recipe generated by EasyBuild, using the following command:
```console
eb Python-3.6.4-foss-2018a.eb OpenMPI-2.1.2-GCC-6.4.0-2.28.eb -C --container-base shub:shahzebsiddiqui/eb-singularity:centos-7.4.1708 --experimental
......@@ -101,16 +101,16 @@ ml Python/3.6.4-foss-2018a OpenMPI/2.1.2-GCC-6.4.0-2.28
```
!!! note
We also specify the easyconfig file for the OpenMPI component of foss/2018a here, because it requires specific OS dependencies to be installed (see the 2nd yum ... install line in the generated container recipe).
We also specify the easyconfig file for the OpenMPI component of foss/2018a here, because it requires specific OS dependencies to be installed (see the second yum ... install line in the generated container recipe).
We intend to let EasyBuild take into account the OS dependencies of the entire software stack automatically in a future update.
The generated container recipe includes pip install -U easybuild to ensure that the latest version of EasyBuild is used to build the software in the container image, regardless of whether EasyBuild was already present in the container and which version it was.
In addition, the generated module files will follow the default module naming scheme (EasyBuildMNS). The modules that correspond to the easyconfig files that were specified on the command line will be loaded automatically, see the statements in the %environment section of the generated container recipe.
In addition, the generated module files will follow the default module-naming scheme (EasyBuildMNS). The modules that correspond to the easyconfig files that were specified on the command line will be loaded automatically; see the statements in the %environment section of the generated container recipe.
## Example of Building Container Image
You can instruct EasyBuild to also build the container image by also using `--container-build-image`.
You can instruct EasyBuild to also build the container image by using `--container-build-image`.
Note that you will need to enter your sudo password (unless you recently executed a sudo command in the same shell session):
......@@ -147,7 +147,7 @@ Cleaning up...
== Temporary directory /tmp/eb-aYXYC8 has been removed.
```
The inspect the container image, you can use `singularity shell` to start a shell session in the container:
To inspect the container image, you can use `singularity shell` to start a shell session in the container:
```console
$ singularity shell --shell "/bin/bash --norc" $HOME/.local/easybuild/containers/GCC-6.4.0-2.28.simg
......@@ -202,7 +202,7 @@ Use `eb --show-full-config | grep containerpath` to determine the currently acti
### Container Image Format
The format for container images that EasyBuild is produces via the functionality provided by the container software can be controlled via the `--container-image-format` configuration setting.
The format for container images that EasyBuild produces via the functionality provided by the container software can be controlled via the `--container-image-format` configuration setting.
For Singularity containers (see Type of container recipe/image to generate (`--container-type`)), three image formats are supported:
......@@ -214,11 +214,11 @@ See also [link][d] [link][e].
## Name for Container Recipe & Image
By default, EasyBuild will use the name of the first easyconfig file (without the .eb suffix) as a name for both the container recipe and image.
By default, EasyBuild will use the name of the first easyconfig file (without the .eb suffix) as a name for both the container recipe and the image.
You can specify an altername name using the `--container-image-name` configuration setting.
You can specify an alternate name using the `--container-image-name` configuration setting.
The filename of generated container recipe will be `Singularity`.<name>.
The filename of the generated container recipe will be `Singularity`.<name>.
The filename of the container image will be `<name><extension>`, where the value for `<extension>` depends on the image format (see Container image format (`--container-image-format`)):
......@@ -228,19 +228,19 @@ The filename of the container image will be `<name><extension>`, where the value
### Temporary Directory for Creating Container Images
The container software that EasyBuild leverages to build container images may be using a temporary directory in a location that doesn’t have sufficient free space.
The container software that EasyBuild leverages to build container images may be using a temporary directory in a location that does not have sufficient free space.
You can instruct EasyBuild to pass an alternate location via the `--container-tmpdir` configuration setting.
For Singularity, the default is to use /tmp, [see][f]. If `--container-tmpdir` is specified, the `$SINGULARITY_TMPDIR` environment variable will be defined accordingly to let Singularity use that location instead.
Type of container recipe/image to generate (`--container-type`)
With the `--container-type` configuration option, you can specify what type of container recipe/image EasyBuild should generated. Possible values are:
Type of container recipe/image to generate (`--container-type`).
With the `--container-type` configuration option, you can specify what type of container recipe/image EasyBuild should generate. Possible values are:
* singularity (default): [Singularity][g] container recipes & images
* docker: [Docker][h] container recipe & images
For detailed documentations see [here][i].
For detailed documentation, see the [webpage][i].
[a]: https://hub.docker.com/
[b]: https://singularity-hub.org/
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment