From 9367c6dca9898ab6478ead8fe9e900a72229a281 Mon Sep 17 00:00:00 2001 From: timkphd <49761448+timkphd@users.noreply.github.com> Date: Mon, 13 May 2019 12:56:39 -0600 Subject: [PATCH 1/3] Add files via upload --- sing2 | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 sing2 diff --git a/sing2 b/sing2 new file mode 100644 index 0000000..f0bf953 --- /dev/null +++ b/sing2 @@ -0,0 +1,43 @@ +Bootstrap: library +From: ubuntu:18.04 + +%setup + touch /file1 + touch ${SINGULARITY_ROOTFS}/file2 + +%files + /file1 + /file1 /opt + +%environment + export LISTEN_PORT=12345 + export LC_ALL=C + +%post + apt-get update && apt-get install -y netcat + NOW=`date` + echo "export NOW=\"${NOW}\"" >> $SINGULARITY_ENVIRONMENT + +%runscript + echo "Container was created $NOW" + echo "Arguments received: $*" + exec echo "$@" + +%startscript + nc -lp $LISTEN_PORT + +%test + grep -q NAME=\"Ubuntu\" /etc/os-release + if [ $? -eq 0 ]; then + echo "Container base is Ubuntu as expected." + else + echo "Container base is not Ubuntu." + fi + +%labels + Author d@sylabs.io + Version v0.0.1 + +%help + This is a demo container used to illustrate a def file that uses all + supported sections. \ No newline at end of file From 02c1af5f7dbde70ac77c73500a33d1bfcdfe68ea Mon Sep 17 00:00:00 2001 From: timkphd <49761448+timkphd@users.noreply.github.com> Date: Mon, 13 May 2019 13:04:09 -0600 Subject: [PATCH 2/3] Update sing2 --- sing2 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sing2 b/sing2 index f0bf953..cf9e0d4 100644 --- a/sing2 +++ b/sing2 @@ -15,6 +15,7 @@ From: ubuntu:18.04 %post apt-get update && apt-get install -y netcat + apt install -y gfortran NOW=`date` echo "export NOW=\"${NOW}\"" >> $SINGULARITY_ENVIRONMENT @@ -40,4 +41,4 @@ From: ubuntu:18.04 %help This is a demo container used to illustrate a def file that uses all - supported sections. \ No newline at end of file + supported sections. From 823b72748f1239cff70ad1ec8bd6f311fe3ebc20 Mon Sep 17 00:00:00 2001 From: timkphd <49761448+timkphd@users.noreply.github.com> Date: Mon, 13 May 2019 13:10:11 -0600 Subject: [PATCH 3/3] Update sing2 --- sing2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sing2 b/sing2 index cf9e0d4..7d67654 100644 --- a/sing2 +++ b/sing2 @@ -1,4 +1,4 @@ -Bootstrap: library +Bootstrap: docker From: ubuntu:18.04 %setup