This project installs and configures the Singularity container system.
Singularity is a system for building and running Linux Containers. See the Singularity project site for more information and documentation.
The project includes an example cluster template which adds Singularity to a PBS grid. But the Singularity project is intended primarily as an additional capability that can be added to any Cyclecloud cluster.
Table of Contents
This sample requires the following:
-
The Singularity source tarball or the Singularity RPM or DEB files (depending on the OS you select for your cluster).
a. Download the source or binaries following the instructions here: (https://singularity.lbl.gov/install-linux)
- To download the source, you can simply run:
curl -L -O https://github.com/singularityware/singularity/releases/download/$VERSION/singularity-2.4.5.tar.gzb. Place the source tarball and/or package files in the./blobs/directory. c. If the version is not 2.4.5 (the project default), then update the version number in the Files list in./project.iniand in the cluster template:./templates/pbs-singularity.txt. d. If you are starting from the package files, also add the package file names to the Files list in./project.ini
- To download the source, you can simply run:
-
CycleCloud must be installed and running.
a. If this is not the case, see the CycleCloud QuickStart Guide for assistance.
-
The CycleCloud CLI must be installed and configured for use.
-
You must have access to log in to CycleCloud.
-
You must have access to upload data and launch instances in your chosen Cloud Provider account.
-
You must have access to a configured CycleCloud "Locker" for Project Storage (Cluster-Init and Chef).
-
Optional: To use the
cyclecloud project upload <locker>command, you must have a Pogo configuration file set up with write-access to your locker.a. You may use your preferred tool to interact with your storage "Locker" instead.
The first step is to configure the project for use with your storage locker:
-
Open a terminal session with the CycleCloud CLI enabled.
-
Switch to the singularity project directory.
-
Copy the following source tarballs and/or RPM and DEB files to
./blobs -
If the version number is not 2.4.5, update the version numbers in
project.iniandtemplates/pbs-singularity.txt -
If adding the RPM and/or DEB files, add them to the Files list in the
project.ini
To upload the project (including any local changes) to your target locker, run the
cyclecloud project upload command from the project directory. The expected output looks like
this:
$ cyclecloud project upload my_locker
Sync completed!
IMPORTANT
For the upload to succeed, you must have a valid Pogo configuration for your target Locker.
To import the cluster:
-
Open a terminal session with the CycleCloud CLI enabled.
-
Switch to the Singularity project directory.
-
Run
cyclecloud import_template PBS-Singularity -f templates/pbs-singularity.txt. The expected output looks like this:$ cyclecloud import_template PBS-Singularity -f templates/pbs-singularity.txt --force Importing template PBS-Singularity.... ---------------------------- PBS-Singularity : *template* ---------------------------- Keypair: Cluster nodes: master: off Total nodes: 1