# Copyright (c) 2016, Ontropos, Inc. All rights reserved.
#
# Copyright (c) 2015-2017, Gregory M. Kurtzer. All rights reserved.
# 
# "Singularity" Copyright (c) 2016, The Regents of the University of California,
# through Lawrence Berkeley National Laboratory (subject to receipt of any
# required approvals from the U.S. Dept. of Energy).  All rights reserved.

BootStrap: debootstrap
OSVersion: trusty
MirrorURL: http://archive.ubuntu.com/ubuntu/
Include: bash

%post
    apt-get -y install wget apt-transport-https
    sed -i 's/main/main restricted universe/g' /etc/apt/sources.list
    echo 'deb http://download.openfoam.org/ubuntu trusty main' >> /etc/apt/sources.list
    wget -O - http://dl.openfoam.org/gpg.key | apt-key add -
    apt-get update
    apt-get -y install openfoam4
    apt-get clean
    echo ". /opt/openfoam4/etc/bashrc" >> /environment

