Bootstrap:docker
From:neurodebian:non-free

%post
    echo "Configuring the environment"
    apt-get -y update

    # setup the container sources themselves
    apt-get -y install eatmydata
    # proper locale setup for UTF8
    eatmydata apt-get -y install locales
    echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen
    locale-gen

    # the least possible bit of FSL
    eatmydata apt-get -y install --no-install-recommends fsl-5.0-core fsl-mni152-templates

    # and some dependencies that it doesnt declare...shame!
    eatmydata apt-get -y install --no-install-recommends file

    # clean up
    apt-get clean

    # inject FSL setup
    ln -fs /etc/fsl/5.0/fsl.sh /.singularity.d/env/99-fsl.sh
