monaghaa/build_container_on_shub2:latest

$ singularity pull shub://monaghaa/build_container_on_shub2:latest

Singularity Recipe

Bootstrap:docker  
From:ubuntu:latest

%labels
MAINTAINER Andy Monaghan
DATE 2019-08-09

%environment
CODE_DIR=/opt
export CODE_DIR  

%files
#copy files into container /opt directory
     text_translate.py /opt

%post  
echo "This section is performed after you bootstrap to build the image."  
#install needed base packages
apt-get update
apt-get install -y vim nano 
apt-get install -y python-dev python-pip python-setuptools

#install needed python packages
pip install translate

%runscript
echo "This code executed when you run the image!" 
exec python /opt/text_translate.py 

%help
#This provides help to users of the container

A base Ubuntu Singularity container with a basic Python installation and the "translate" package
To run the example script:
>singularity run <image_name>.sif"

Or to run python on your own external script:
>singularity exec <image_name>.sif python <your_script_name>.py
which is equivalent to running "python [arguments]"

%test
# Sanity check that the container is operating
# Check python version
    /usr/bin/python --version

Collection


View on Datalad

Metrics

key value
id /containers/monaghaa-build_container_on_shub2-latest
collection name monaghaa/build_container_on_shub2
branch master
tag latest
commit c59bc5aea86e0d93c9b8f7f945efd95f09a02cec
version (container hash) 427c9e97248bbe416c2199a066279b2ef84b1174ba4928776444abf0f3dc339f
build date 2019-08-09T17:50:39.708Z
size (MB) 201.12890625
size (bytes) 210898944
SIF Download URL (please use pull with shub://)
Datalad URL View on Datalad
Singularity Recipe Singularity Recipe on Datalad
We cannot guarantee that all containers will still exist on GitHub.