51 lines
1.3 KiB
Modula-2
51 lines
1.3 KiB
Modula-2
Bootstrap: docker
|
|
From: mcr.microsoft.com/dotnet/sdk:9.0
|
|
Stage: build
|
|
|
|
%files
|
|
. /build
|
|
|
|
%post
|
|
apt-get update && apt-get install -y ca-certificates gnupg
|
|
mkdir -p /etc/apt/keyrings
|
|
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
|
|
NODE_MAJOR=20
|
|
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
|
|
|
|
# Install node, 7zip, yarn, git, process tools
|
|
apt update \
|
|
&& apt install -y nodejs p7zip-full git procps ssh-client libnetcdf19 libnetcdf-dev
|
|
|
|
# Clean up
|
|
apt autoremove -y \
|
|
&& apt clean -y \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Install dotnet tools
|
|
dotnet tool restore
|
|
|
|
cd /build
|
|
dotnet run bundle
|
|
|
|
Bootstrap: docker
|
|
From: mcr.microsoft.com/dotnet/runtime:9.0
|
|
Stage: runtime
|
|
|
|
%files from build
|
|
/build/dist /app
|
|
|
|
%post
|
|
apt update \
|
|
&& apt install -y libnetcdf19
|
|
|
|
apt autoremove -y \
|
|
&& apt clean -y \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
cp -s /usr/lib/x86_64-linux-gnu/libdl.so.2 /usr/lib/x86_64-linux-gnu/libdl.so
|
|
cp /usr/lib/x86_64-linux-gnu/libnetcdf.so.19 /usr/lib/libnetcdf.so
|
|
|
|
%environment
|
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/x86_64-linux-gnu
|
|
|
|
%runscript
|
|
exec /app/Tzar "$@" |