-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Singularity guide #120
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
## Importing a Rocker Image | ||
|
||
Use the `singularity pull` command to import the desired Rocker image from Docker Hub into a (compressed, read-only) Singularity Image File: | ||
|
||
```bash | ||
singularity pull docker://rocker/rstudio:4.2 | ||
singularity pull docker://rocker/rstudio:4.4.2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about rocker/rstudio:4
?
/usr/lib/rstudio-server/bin/rserver --www-address=127.0.0.1 | ||
--scratch /run,/var/lib/rstudio-server \ | ||
--workdir $(mktemp -d) \ | ||
rstudio_4.4.2.sif \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
rstudio_4.2.sif \ | ||
/usr/lib/rstudio-server/bin/rserver --auth-none=0 --auth-pam-helper-path=pam-helper --server-user=$(whoami) | ||
--scratch /run,/var/lib/rstudio-server \ | ||
rstudio_4.4.2.sif \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
# personal libraries from any R installation in the host environment | ||
|
||
R_LIBS_USER=${HOME}/R/rocker-rstudio/4.4.2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
singularity exec --cleanenv \ | ||
--scratch /run,/tmp,/var/lib/rstudio-server \ | ||
--workdir ${workdir} \ | ||
rstudio_4.4.2.sif \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
:::{.callout-note} | ||
In this guide, *Singularity* can refer to either [SingularityCE](https://sylabs.io/singularity/) or [Apptainer](https://apptainer.org/). | ||
While Apptainer is generally [compatible with Singularity commands and environment variables](https://apptainer.org/docs/user/latest/singularity_compatibility.html), Apptainer users may wish to replace the `singularity` command with `apptainer`, and `SINGULARITY` with `APPTAINER` in environment variables. | ||
::: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Empty lines are needed around :::
:::{.callout-note} | |
In this guide, *Singularity* can refer to either [SingularityCE](https://sylabs.io/singularity/) or [Apptainer](https://apptainer.org/). | |
While Apptainer is generally [compatible with Singularity commands and environment variables](https://apptainer.org/docs/user/latest/singularity_compatibility.html), Apptainer users may wish to replace the `singularity` command with `apptainer`, and `SINGULARITY` with `APPTAINER` in environment variables. | |
::: | |
:::{.callout-note} | |
In this guide, *Singularity* can refer to either [SingularityCE](https://sylabs.io/singularity/) or [Apptainer](https://apptainer.org/). | |
While Apptainer is generally [compatible with Singularity commands and environment variables](https://apptainer.org/docs/user/latest/singularity_compatibility.html), Apptainer users may wish to replace the `singularity` command with `apptainer`, and `SINGULARITY` with `APPTAINER` in environment variables. | |
::: |
Updates the Singularity guide:
rserver --server-user
in job script (singularity on HPC with slurm rocker-versioned2#837)(Specify .Rprofile and .Renviron when using singularity rocker-versioned2#855)
python3
instead ofpython
(the latter may be python 2 or absent on some hosts)--scratch
and--workdir
(though shouldn't make a difference with a single-node allocation)