While there are many container solutions being used commonly in this day and age, what makes Singularity different stems from it’s primary design features
Size: 2.8 MB
Language: en
Added: Oct 27, 2017
Slides: 13 pages
Slide Content
Singularity RAMAR BOSE RESEARCH SCHOLAR
CONTAINERS Package software into standardized units for development, shipment and deployment A container image is a lightweight, stand-alone, executable package of a piece of software that includes everything needed to run it: code, runtime, system tools, system libraries, settings.
Containers and Virtual Machines Singularity
primary design features and thus it’s architecture Reproducible software stacks: These must be easily verifiable via checksum or cryptographic signature in such a manner that does not change formats (e.g. splatting a tarball out to disk). By default Singularity uses a container image file which can be checksummed , signed, and thus easily verified and/or validated. Mobility of compute: Singularity must be able to transfer (and store) containers in a manner that works with standard data mobility tools ( rsync , scp , gridftp , http, NFS, etc..) and maintain software and data controls compliancy (e.g. HIPPA, nuclear, export, classified, etc..) Compatibility with complicated architectures: The runtime must be immediately compatible with existing HPC, scientific, compute farm and even enterprise architectures any of which maybe running legacy kernel versions (including RHEL6 vintage systems) which do not support advanced namespace features (e.g. the user namespace) Security model: Unlike many other container systems designed to support trusted users running trusted containers we must support the opposite model of untrusted users running untrusted containers. This changes the security paradigm considerably and increases the breadth of use cases we can support.
Singularity has two primary roles Container Image Generator: Singularity supports building different container image formats from scratch using your choice of Linux distribution bases or leveraging other container formats (e.g. Docker Hub). Container formats supported are the default compressed immutable (read only) image files, writable raw file system based images, and sandboxes ( chroot style directories). Container Runtime: The Singularity runtime is designed to leverage the above mentioned container formats and support the concept of untrusted users running untrusted containers . This counters the typical container runtime practice of trusted users running trusted containers and as a result of that, Singularity utilizes a very different security paradigm. This is a required feature for implementation within any multi-user environment.
Install on Linux Download latest stable release $ Wget https://github.com/singularityware/singularity/releases/download/$VERSION/singularity-$VERSION.tar.gz $tar xvf singularity-$VERSION.tar.gz $cd singularity-$VERSION $./configure --prefix = / usr /local Make sudo make install
Host a Singularity Registry Singularity Registry is a management and storage of Singularity images for an institution or user to deploy locally. It does not manage building, but serves endpoints to obtain and save containers. The Registry is expected to be available for use in the Fall. build to your on you local resource, or a continuous integration server push images to the registry manage images in collections, by tags, or metadata visualize collections of images to assess size
Create an image on CentOS Identify a CentOS machine with the same major version of CentOS you want to build. Don’t use a CentOS-7 machine to build a CentOS-6 machine, because it won’t work. (Building a CentOS-7 image on a CentOS-6 host works, but the RPM DB would actually be using an older version of Berkeley DB) Install Singularity on this host. Locate the centos.def file from the example/ directory. Edit to your heart’s desire ( eg change OSVersion ). Create the image, bootstrap, and run: