Skip to content
Snippets Groups Projects
Commit e160f880 authored by thawn's avatar thawn
Browse files

enable installation on other clusters

... that do not use symlinks for the home directory
closes issue #10
parent 8fbcfecf
No related branches found
No related tags found
No related merge requests found
Pipeline #11573 canceled
......@@ -14,12 +14,16 @@ fi
set -e
version=${1:-latest}
source environment.sh
userhome=$(ls -l "$HOME" | cut -d ">" -sf 2)
userhome=${userhome## }
if [ -L "$HOME" ]; then
userhome=$(ls -l "$HOME" | cut -d ">" -sf 2)
userhome=/home/${userhome## }
else
userhome=$HOME
fi
container_name=${IMAGE_NAME%.sif}_$version
echo "Downloading the image may take a while and does not show a progress bar. Please be patient :) ..."
if [ "${IMAGE_PATH%.sif}" == "${IMAGE_PATH}" ]; then
local_path="/home/${userhome}/singularity-images/"
local_path="${userhome}/singularity-images/"
local_image="${local_path}${container_name}.sif"
mkdir -p "$local_path"
singularity pull "$local_image" "${IMAGE_PATH}:$version"
......
......@@ -10,13 +10,13 @@
"--pwd",
"{cwd}",
"-B",
"/home/<userhome>/.local/share/jupyter/runtime",
"<userhome>/.local/share/jupyter/runtime",
"-B",
"/home/<userhome>/",
"<userhome>/",
"-B",
"/etc/OpenCL",
"-B",
"/home/<userhome>/.ssh:/.ssh",
"<userhome>/.ssh:/.ssh",
"-B",
"/projects",
"-B",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment