forked from powerPlant/apsimx-srf
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Singularity.2021.10.8.6835
34 lines (27 loc) · 1.03 KB
/
Singularity.2021.10.8.6835
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
Bootstrap: docker
From: ubuntu:focal
%labels
Maintainer [email protected]
Version 2021.10.8.6835
%setup
curl --silent -o ${SINGULARITY_ROOTFS}/ApsimSetup.deb http://apsimdev.apsim.info/ApsimXFiles/apsim-6835.deb
curl --silent -o ${SINGULARITY_ROOTFS}/packages-microsoft-prod.deb https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb
%post
export DEBIAN_FRONTEND=noninteractive
## Install .NET Runtime, libsqlite3 and tzdata
apt-get update
apt -y install /packages-microsoft-prod.deb
apt-get update
apt-get -y install dotnet-runtime-3.1 libsqlite3-dev tzdata
## Configure timezone
ln -fs /usr/share/zoneinfo/Pacific/Auckland /etc/localtime && dpkg-reconfigure -f noninteractive tzdata
## Install from deb file
apt -y install --no-install-recommends /ApsimSetup.deb
## Fix entrypoint
chmod +x /usr/local/bin/*
## Cleanup
rm -rf /ApsimSetup.deb /packages-microsoft-prod.deb
apt-get -y clean all
apt-get -y autoremove --purge
%runscript
exec /usr/local/bin/Models "$@"