2023-01-18 13:25:18 +03:00
|
|
|
# OS
|
|
|
|
ARG VARIANT="ubuntu-22.04"
|
|
|
|
|
|
|
|
FROM mcr.microsoft.com/vscode/devcontainers/base:0-${VARIANT}
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
|
|
ENV BOOTSTRAP_HASKELL_NONINTERACTIVE=1
|
2023-08-11 12:49:33 +03:00
|
|
|
ENV BOOTSTRAP_HASKELL_GHC_VERSION=9.4.5
|
2023-05-15 13:06:18 +03:00
|
|
|
ENV BOOTSTRAP_HASKELL_CABAL_VERSION=3.10.1.0
|
2023-08-11 12:49:33 +03:00
|
|
|
ENV BOOTSTRAP_HASKELL_STACK_VERSION=2.11.1
|
2023-01-18 13:25:18 +03:00
|
|
|
ENV BOOTSTRAP_HASKELL_INSTALL_STACK=1
|
|
|
|
ENV BOOTSTRAP_HASKELL_INSTALL_HLS=1
|
|
|
|
|
|
|
|
# OS packages for ghcup and juvix runtime
|
|
|
|
RUN apt-get update && \
|
2023-06-20 15:19:27 +03:00
|
|
|
apt-get -y install --no-install-recommends \
|
|
|
|
curl \
|
|
|
|
sudo \
|
|
|
|
wget \
|
|
|
|
unzip \
|
|
|
|
git \
|
|
|
|
jq \
|
|
|
|
bc \
|
|
|
|
make \
|
|
|
|
cmake \
|
|
|
|
clang \
|
|
|
|
lldb \
|
|
|
|
lld \
|
|
|
|
llvm \
|
|
|
|
automake \
|
|
|
|
rsync \
|
|
|
|
htop \
|
|
|
|
build-essential \
|
|
|
|
lsb-release \
|
|
|
|
pkg-config \
|
|
|
|
libffi-dev \
|
|
|
|
libgmp-dev \
|
|
|
|
libgmp10 \
|
|
|
|
software-properties-common \
|
|
|
|
libssl-dev \
|
|
|
|
libicu-dev \
|
|
|
|
libtinfo-dev \
|
|
|
|
libsystemd-dev \
|
|
|
|
zlib1g-dev \
|
|
|
|
g++ \
|
|
|
|
libncurses-dev \
|
|
|
|
libncursesw5 \
|
|
|
|
libtinfo5 \
|
|
|
|
libtool \
|
|
|
|
autoconf && apt-get clean
|
2023-01-18 13:25:18 +03:00
|
|
|
|
|
|
|
RUN sudo bash -c 'curl -sSL https://get.haskellstack.org/ | sh'
|
|
|
|
|
|
|
|
ENV PATH=${PATH}:/home/vscode/.ghcup/bin
|
|
|
|
|
2023-06-20 15:19:27 +03:00
|
|
|
RUN sudo bash -c "curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | sh"
|
|
|
|
|
2023-01-18 13:25:18 +03:00
|
|
|
ENV PATH=${PATH}:/home/vscode/.local/bin
|
|
|
|
RUN sudo bash -c 'mkdir -p /home/vscode/.local/bin'
|
|
|
|
RUN sudo bash -c "chown -R vscode /home/vscode/.local/"
|
|
|
|
|
|
|
|
RUN sudo bash -c 'curl https://get.wasmer.io -sSfL | sudo WASMER_DIR=/home/vscode/.local sh'
|
|
|
|
|
|
|
|
# to be used by the juvix extension
|
|
|
|
RUN sudo bash -c 'mkdir -p /home/vscode/.local/juvix'
|
|
|
|
RUN sudo bash -c 'chmod -R a+rXw /home/vscode/.local/juvix'
|
|
|
|
|
2023-06-20 15:19:27 +03:00
|
|
|
RUN sudo bash -c 'curl --proto "=https" --tlsv1.2 -sSfL https://get.juvix.org \
|
|
|
|
| sudo XDG_BIN_HOME=/home/vscode/.local/bin JUVIX_INSTALLER_INSTALL_VAMPIR_YES=true JUVIX_INSTALLER_ASSUME_YES=true sh'
|
2023-01-18 13:25:18 +03:00
|
|
|
|
|
|
|
RUN sudo bash -c 'mkdir -p /home/vscode/.local/wasi-sysroot'
|
|
|
|
RUN sudo bash -c 'curl -s https://api.github.com/repos/WebAssembly/wasi-sdk/releases/tags/wasi-sdk-16 \
|
|
|
|
| grep -a "browser_download_url.*wasi-sysroot-16.*tar.gz" \
|
|
|
|
| cut -d : -f 2,3 \
|
|
|
|
| tr -d \" \
|
|
|
|
| wget --output-document wasi-sysroot.tar.gz -qi - \
|
|
|
|
&& tar xvf wasi-sysroot.tar.gz --directory /home/vscode/.local/wasi-sysroot/'
|
|
|
|
ENV WASI_SYSROOT_PATH=/home/vscode/.local/wasi-sysroot/
|
|
|
|
|
|
|
|
RUN sudo bash -c 'curl -s https://api.github.com/repos/jonaprieto/smoke/releases/latest \
|
|
|
|
| grep -a "browser_download_url.*Linux" \
|
|
|
|
| cut -d : -f 2,3 \
|
|
|
|
| tr -d \" \
|
|
|
|
| wget --output-document smoke -qi - \
|
|
|
|
&& mv smoke /home/vscode/.local/bin/smoke \
|
|
|
|
&& chmod a+x /home/vscode/.local/bin/smoke'
|