Skip to content
Snippets Groups Projects
Commit c87413d3 authored by Quang tru HUYNH's avatar Quang tru HUYNH
Browse files

singularity build example

parent 6ee8829b
No related branches found
No related tags found
No related merge requests found
Pipeline #65819 passed
...@@ -109,6 +109,46 @@ PYTHONNOUSERSITE=1 ...@@ -109,6 +109,46 @@ PYTHONNOUSERSITE=1
export PYTHONNOUSERSITE export PYTHONNOUSERSITE
``` ```
## Full example output on the gpulab
```
[tru@adm pythonnet]$ wget https://gitlab.pasteur.fr/tru/conda-container-howto/-/
raw/main/Singularity
--2021-09-23 14:06:00-- https://gitlab.pasteur.fr/tru/conda-container-howto/-/raw/main/Singularity
Resolving gitlab.pasteur.fr (gitlab.pasteur.fr)... 157.99.21.44
Connecting to gitlab.pasteur.fr (gitlab.pasteur.fr)|157.99.21.44|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 769 [text/plain]
Saving to: ‘Singularity’
100%[======================================>] 769 --.-K/s in 0s
2021-09-23 14:06:00 (115 MB/s) - ‘Singularity’ saved [769/769]
[tru@adm pythonnet]$ sudo singularity build b.sif Singularity INFO: Starting build...
Getting image source signatures
Copying blob 2d473b07cdd5 [--------------------------------------] 0.0b / 0.0b
Copying config 6d42e44a9f done
Writing manifest to image destination
<...>
#
# To activate this environment, use
#
# $ conda activate pythonnet
#
# To deactivate an active environment, use
#
# $ conda deactivate
INFO: Adding environment to container
INFO: Creating SIF file...
INFO: Build complete: b.sif
[tru@adm pythonnet]$ ./b.sif
Singularity> eval "$(conda shell.bash hook)"
(base) Singularity> conda activate pythonnet
(pythonnet) Singularity> python -c 'import clr'
(pythonnet) Singularity>
```
Now you just need to distribute your container... to whoever/wherever.
## Caveats ## Caveats
- adding to base and adding a new pythonnet env are different things... - adding to base and adding a new pythonnet env are different things...
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment