## Initial setup of Docker worker VM Start the Docker daemon and a local Docker registry. ```sh sudo systemctl start docker sudo docker run -d -p 5000:5000 --restart=always --name registry registry:2 ``` Place `repo2singularity` (see file in this gist) in `/usr/bin/` or somewhere on the `PATH`. ## Build a Singularity image from a Binder-compatible repo Clone the Binder-compatible repo and ``` git clone REPO_URL REPO_DIRECTORY repo2singularity REPO_DIRECTORY IMAGE_NAME ``` This generates a `.sif` file in `/tmp/sifs`. Copy it to `nslshub01`. ``` scp /tmp/sifs/IMAGE_NAME nslshub01:/srv/jupyter/scontainers_available/ ``` ## Make it available to users On `nslshub01`, create a soft link targeting `/srv/jupyter/scontainers_available/` from `/srv/jupyter/scontainers/`. ```sh ln -s -T /srv/jupyter/scontainers_available/NAME /srv/jupyter/scontainers/NAME ```