frankwillmore/singularity_image_recipes:heres_johnny

$ singularity pull shub://frankwillmore/singularity_image_recipes:heres_johnny

Singularity Recipe

Bootstrap: docker
From: centos

%setup
   # setup is run after the base 'centos' image is
   # downloaded and upacked but before entering the 
   # container environment
   
   # Frank wuz here
   
   # this is the path on the local system to 
   # what will become your container's root directory
   echo ${SINGULARITY_ROOTFS}
   # create a directory for your application
   mkdir ${SINGULARITY_ROOTFS}/myapp
   # copy the hello world example from the github to 
   # the app directory
   cp example_codes/hello_world.cpp ${SINGULARITY_ROOTFS}/myapp/

%post
   # post is run after entering the container env. 
   
   # need to install some development tools to
   # build our code
   yum update -y
   yum groupinstall -y "Development Tools"
   yum install -y gcc g++
   
   # enter directory where source file was copied
   cd /myapp
   
   # build
   g++ -o hello_world hello_world.cpp

%runscript
   # run script
   /myapp/hello_world

%environment
   # can define runtime environment variables here
   # these vars will be set during calls to 'shell'
   # or 'exec' or 'run' but will not be set during
   # the previous 'post' section of the recipe file
   # so, if you need them, define them there as well
   export PATH=$PATH:/myapp

Collection


View on Datalad

Metrics

key value
id /containers/frankwillmore-singularity_image_recipes-heres_johnny
collection name frankwillmore/singularity_image_recipes
branch master
tag heres_johnny
commit 1ed2dc400328e229944ff7465a9049616f5865b1
version (container hash) bc6a2187c22369f68fecaea1c3a90296
build date 2019-06-07T11:19:42.501Z
size (MB) 601
size (bytes) 196354079
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.