# SINGULARITY.CONF
# This is the global configuration file for Singularity. This file controls
# what the container is allowed to do on a particular host, and as a result
# this file must be owned by root.


# ALLOW SETUID: [BOOL]
# DEFAULT: yes
# Should we allow users to utilize the setuid binary for launching singularity?
# The majority of features require this to be set to yes, but newer Fedora and
# Ubuntu kernels can provide limited functionality in unprivileged mode.
allow setuid = yes


# ALLOW PID NS: [BOOL]
# DEFAULT: yes
# Should we allow users to request the PID namespace?
allow pid ns = yes


# ENABLE OVERLAY: [BOOL]
# DEFAULT: yes
# Enabling this option will make it possible to specify bind paths to locations
# that do not currently exist within the container. Some limitations still exist
# when running in completely non-privileged mode. (note: this option is only
# supported on hosts that support overlay file systems).
# note: currently disabled because RHEL7 kernel crashes with it... :(
enable overlay = no


# CONFIG PASSWD: [BOOL]
# DEFAULT: yes
# If /etc/passwd exists within the container, this will automatically append
# an entry for the calling user.
config passwd = yes


# CONFIG GROUP: [BOOL]
# DEFAULT: yes
# If /etc/group exists within the container, this will automatically append
# an entry for the calling user.
config group = yes


# CONFIG RESOLV_CONF: [BOOL]
# DEFAULT: yes
# If there is a bind point within the container, use the host's
# /etc/resolv.conf.
config resolv_conf = yes


# MOUNT PROC: [BOOL]
# DEFAULT: yes
# Should we automatically bind mount /proc within the container?
mount proc = yes


# MOUNT SYS: [BOOL]
# DEFAULT: yes
# Should we automatically bind mount /sys within the container?
mount sys = yes


# MOUNT DEV: [yes/no/minimal]
# DEFAULT: yes
# Shoudl we automatically bind mount /dev within the container? If you select
# minimal, and if overlay is enabled, then Singularity will attempt to create
# the following devices inside the container: null, zero, random, urandom
# note: This requires 'enable overlay = yes'
mount dev = yes


# MOUNT HOME: [BOOL]
# DEFAULT: yes
# Should we automatically determine the calling user's home directory and
# attempt to mount it's base path into the container? If the --contain option
# is used, the home directory will be created within the session directory or
# can be overridden with the SINGULARITY_HOME or SINGULARITY_WORKDIR
# environment variables (or their corresponding command line options).
mount home = yes


# MOUNT TMP: [BOOL]
# DEFAULT: yes
# Should we automatically bind mount /tmp and /var/tmp into the container? If
# the --contain option is used, both tmp locations will be created in the
# session directory or can be specified via the  SINGULARITY_WORKDIR
# environment variable (or the --workingdir command line option).
mount tmp = yes


# MOUNT HOSTFS: [BOOL]
# DEFAULT: no
# Probe for all mounted file systems that are mounted on the host, and bind
# those into the container?
mount hostfs = no


# BIND PATH: [STRING]
# DEFAULT: Undefined
# Define a list of files/directories that should be made available from within
# the container. The file or directory must exist within the container on
# which to attach to. you can specify a different source and destination
# path (respectively) with a colon; otherwise source and dest are the same.
#bind path = /etc/singularity/default-nsswitch.conf:/etc/nsswitch.conf
#bind path = /opt
#bind path = /scratch
bind path = /etc/hosts


# USER BIND CONTROL: [BOOL]
# DEFAULT: yes
# Allow users to influence and/or define bind points at runtime? This will allow
# users to specify bind points, scratch and tmp locations. (note: User bind
# control is only allowed if the host also supports PR_SET_NO_NEW_PRIVS)
user bind control = yes


# MOUNT SLAVE: [BOOL]
# DEFAULT: yes
# Should we automatically propagate file-system changes from the host?
# This should be set to 'yes' when autofs mounts in the system should
# show up in the container.
mount slave = yes


# CONTAINER DIR: [STRING]
# DEFAULT: /var/lib/singularity/mnt
# This path specifies the location to use for mounting the container, overlays
# and other necessary file systems for the container. Note, this location
# absolutely must be local on this host.
container dir = /var/lib/singularity/mnt


# SESSIONDIR PREFIX: [STRING]
# DEFAULT: /tmp/.singularity-session-
# This specifies the prefix for the session directory. Appended to this string
# is an identification string unique to each user and container. Note, this
# location absolutely must be local on this host. If the default location of
# /tmp/ does not work for your system, /var/lib/singularity/sessions maybe a
# better option.
#sessiondir prefix = /var/lib/singularity/sessions/

