Commit 1273dcf8 authored by Alex Waite's avatar Alex Waite

singularity: cleanup readme (tweak language; wrap lines)

parent 667b0a32
......@@ -11,4 +11,4 @@ If you see something that is missing or should be improved, please contribute!
| [matlab](matlab/) | A very simple submit file that passes an argument to a Matlab script. |
| [ncal](ncal/) | The [calendar printing example](https://docs.inm7.de/tools/htcondor/#generating-a-submit) used in the docs. A script is used to generate the submit file. |
| [python](python/) | A very simple submit file that passes an argument to a Python script. |
| [singularity](singularity/) | A simple example on how to build a singularity container. |
| [singularity](singularity/) | Build a simple Singularity container. |
# Singularity
This template demonstrates how to build a singularity container using HTCondor.
The `singularity.submit` file runs a simple shell script `singularity.sh` that collects the singularity recipe file `sl.def`, builds a singularity image `sl.simg` and pushes it back to your directory.
The `singularity.submit` file runs a shell script (`singularity.sh`) that
collects the singularity recipe file (`sl.def`), builds a singularity image
(`sl.simg`), and copies it back to your directory.
To run:
```
condor_submit singularity.submit
```
If you want to build your container in an interactive session, you can use the `singularity-interactive.submit` instead:
If you want to build your container in an interactive session, you can use the
`singularity-interactive.submit` instead:
```
condor_submit --interactive singularity-interactive.submit
```
......@@ -20,20 +23,34 @@ singularity run sl.simg
## Things to Note
- Please note that in this example the singularity container is built on a compute node. This is convenient, because it allows for the job to be completed faster. More on this can be found in the **Further reading** section below.
- Using a `.submit` file allows you use the `rank = IOPS` option, that is to request for machines with faster local disks (it'll prefer, but not require these machines to be used).
- Please note that in this example the singularity container is built on a
compute node. This is convenient, because it allows for the job to be
completed faster. More on this can be found in the **Further Reading** section
below.
- Using a `.submit` file allows you use the `rank = IOPS` option, which will
request machines with faster scratch disks (it'll prefer, but not require
these machines to be used).
## Further reading
## Further Reading
Juseless is a collection of systems. The most important ones are the head node (the one you log into), the data node (which hosts `/home` and `/data`), and the compute nodes.
Juseless is a collection of systems. The most important ones are the head node
(the one you log into), the data node (which hosts `/home` and `/data`), and the
compute nodes.
`/home` and `/data` are shared to all nodes using the Network File System (NFS). This is convenient, because they all can see the same data. But it's obviously slower because everything has to go over the network.
`/home` and `/data` are shared to all nodes using the Network File System (NFS).
This is convenient, because they all can see the same data. But it's obviously
slower because everything has to go over the network.
Each compute node has a dedicated [*scratch disk*](https://docs.inm7.de/htcondor/job_concepts/#scratch-disk) for local temporary files. This is useful because it saves the data node from unneccesary data and traffic, but also benefits jobs which need to read and write a lot. Local disk are faster than the network, so it's a win all around.
Each compute node has a dedicated [*scratch disk*](https://docs.inm7.de/htcondor/job_concepts/#scratch-disk)
for local temporary files. This is useful because it saves the data node from
unnecessary data and traffic, but also benefits jobs which need to read and
write a lot. Local disk are faster than the network, so it's a win all around.
Compute jobs see this *scratch disk* as `/tmp` (the reality is more complex than that).
Compute jobs see this *scratch disk* as `/tmp`. Read the docs linked above for
more detailed information.
## Prerequisites
This example assumes that it is located in `~/htcondor-templates/singularity`. If you have cloned it elsewhere, adjust the submit file as necessary.
This example assumes that it is located in `~/htcondor-templates/singularity`.
If you have cloned it elsewhere, adjust the submit file as necessary.
Otherwise, this example is entirely self contained.
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