diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 70ffb0e..7f0ad21 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -51,7 +51,9 @@ // Live Share "ms-vsliveshare.vsliveshare", // Copilot - "GitHub.copilot" + "GitHub.copilot", + // Quarto + "quarto.quarto" ], // Set *default* container specific settings // Important for radian and latex diff --git a/.github/workflows/build_deploy_dev.yml b/.github/workflows/build_deploy_dev.yml index 5189097..b842816 100644 --- a/.github/workflows/build_deploy_dev.yml +++ b/.github/workflows/build_deploy_dev.yml @@ -36,7 +36,7 @@ jobs: echo "IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')" >> $GITHUB_ENV - name: Build and push - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: true diff --git a/.github/workflows/build_deploy_master.yml b/.github/workflows/build_deploy_master.yml index c2b4430..623b119 100644 --- a/.github/workflows/build_deploy_master.yml +++ b/.github/workflows/build_deploy_master.yml @@ -36,7 +36,7 @@ jobs: echo "IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')" >> $GITHUB_ENV - name: Build and push - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: true diff --git a/.github/workflows/build_deploy_size.yml b/.github/workflows/build_deploy_size.yml index 6bf998e..5da477a 100644 --- a/.github/workflows/build_deploy_size.yml +++ b/.github/workflows/build_deploy_size.yml @@ -35,7 +35,7 @@ jobs: echo "IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')" >> $GITHUB_ENV - name: Build and push - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: true diff --git a/.github/workflows/build_on_pr.yml b/.github/workflows/build_on_pr.yml index cd97ae4..3986fe5 100644 --- a/.github/workflows/build_on_pr.yml +++ b/.github/workflows/build_on_pr.yml @@ -34,7 +34,7 @@ jobs: echo "IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')" >> $GITHUB_ENV - name: Build and push - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: true diff --git a/Dockerfile b/Dockerfile index 5452af2..50acd49 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,9 @@ -FROM ubuntu:jammy@sha256:6d7b5d3317a71adb5e175640150e44b8b9a9401a7dd394f44840626aff9fa94d +FROM ubuntu:jammy@sha256:340d9b015b194dc6e2a13938944e0d016e57b9679963fdeb9ce021daac430221 SHELL ["/bin/bash", "-c"] ENV DISPLAY=:0 \ - TZ=Europe/Berlin + TZ=Europe/Berlin ARG USERNAME=vscode ARG USER_UID=1000 @@ -12,53 +12,54 @@ ARG DEBIAN_FRONTEND=noninteractive # Add non root user RUN groupadd --gid $USER_GID $USERNAME \ - && useradd -rm -d /home/$USERNAME -s /bin/bash -g root --uid $USER_UID --gid $USER_GID $USERNAME \ - && addgroup $USERNAME staff + && useradd -rm -d /home/$USERNAME -s /bin/bash -g root --uid $USER_UID --gid $USER_GID $USERNAME \ + && addgroup $USERNAME staff # Create folders to mount extensions RUN mkdir -p /home/$USERNAME/.vscode-server/extensions \ - /home/$USERNAME/.vscode-server-insiders/extensions \ - workspaces \ - && chown -R $USERNAME \ - /home/$USERNAME/.vscode-server \ - /home/$USERNAME/.vscode-server-insiders \ - workspaces + /home/$USERNAME/.vscode-server-insiders/extensions \ + workspaces \ + && chown -R $USERNAME \ + /home/$USERNAME/.vscode-server \ + /home/$USERNAME/.vscode-server-insiders \ + workspaces # Ubuntu Setup RUN echo "ttf-mscorefonts-installer msttcorefonts/accepted-mscorefonts-eula select true" | debconf-set-selections &&\ - apt-get update &&\ - apt-get -y --no-install-recommends install \ - ca-certificates \ - git \ - build-essential \ - cmake \ - ninja-build \ - ccache \ - gfortran \ - netbase \ - zip \ - unzip \ - xclip \ - zsh \ - gnupg2 \ - nano \ - gdb \ - ssh-client \ - fontconfig \ - pkg-config \ - default-libmysqlclient-dev \ - ttf-mscorefonts-installer \ - locales &&\ - locale-gen en_US.UTF-8 &&\ - locale-gen de_DE.UTF-8 &&\ - update-locale LANG=en_US.UTF-8 &&\ - git clone --depth=1 https://github.com/sindresorhus/pure.git /home/$USERNAME/.zsh/pure \ - && rm -rf /home/$USERNAME/.zsh/pure/.git \ - && apt-get autoclean -y \ - && rm -rf /var/lib/apt/lists/* + apt-get update &&\ + apt-get -y --no-install-recommends install \ + ca-certificates \ + git \ + build-essential \ + cmake \ + ninja-build \ + ccache \ + gfortran \ + netbase \ + zip \ + unzip \ + xclip \ + zsh \ + lftp \ + gnupg2 \ + nano \ + gdb \ + ssh-client \ + fontconfig \ + pkg-config \ + default-libmysqlclient-dev \ + ttf-mscorefonts-installer \ + locales &&\ + locale-gen en_US.UTF-8 &&\ + locale-gen de_DE.UTF-8 &&\ + update-locale LANG=en_US.UTF-8 &&\ + git clone --depth=1 https://github.com/sindresorhus/pure.git /home/$USERNAME/.zsh/pure \ + && rm -rf /home/$USERNAME/.zsh/pure/.git \ + && apt-get autoclean -y \ + && rm -rf /var/lib/apt/lists/* ENV LC_ALL=en_US.UTF-8 \ - LANG=en_US.UTF-8 + LANG=en_US.UTF-8 # Font config # "LM Roman 10", "Times New Roman" ... use `showtext` package in R @@ -71,53 +72,54 @@ RUN fc-cache -f -v # Install quarto ENV QUARTO_VERSION="1.4.551" - COPY install_scripts/install_quarto.sh /install_scripts/install_quarto.sh - RUN chmod +x install_scripts/install_quarto.sh &&\ - install_scripts/install_quarto.sh + install_scripts/install_quarto.sh +RUN wget https://github.com/jgm/pandoc/releases/download/3.1.6.2/pandoc-3.1.6.2-1-amd64.deb &&\ + dpkg -i pandoc-3.1.6.2-1-amd64.deb # Install phantomjs COPY install_scripts/install_phantomjs.sh /install_scripts/install_phantomjs.sh RUN chmod +x install_scripts/install_phantomjs.sh &&\ - install_scripts/install_phantomjs.sh + install_scripts/install_phantomjs.sh # Install vcpkg C++ dependency manager -RUN git clone --depth=1 https://github.com/Microsoft/vcpkg /usr/local/vcpkg \ - && rm -rf /usr/local/vcpkg/.git \ - && cd /usr/local/vcpkg \ - && ./bootstrap-vcpkg.sh \ - && ./vcpkg integrate install \ - && /usr/local/vcpkg/vcpkg install armadillo \ - && /usr/local/vcpkg/vcpkg install pybind11 \ - && chown --recursive $USERNAME:$USERNAME /usr/local/vcpkg +RUN git clone --depth=1 https://github.com/Microsoft/vcpkg --branch 2024.04.26 /usr/local/vcpkg \ + && rm -rf /usr/local/vcpkg/.git \ + && cd /usr/local/vcpkg \ + && ./bootstrap-vcpkg.sh \ + && ./vcpkg integrate install \ + && /usr/local/vcpkg/vcpkg install armadillo \ + && /usr/local/vcpkg/vcpkg install pybind11 \ + && chown --recursive $USERNAME:$USERNAME /usr/local/vcpkg ENV PATH="/usr/local/vcpkg:${PATH}" # Install Python CARMA RUN git clone --depth=1 https://github.com/RUrlus/carma.git /usr/local/carma \ - && rm -rf /usr/local/carma/.git \ - && cd /usr/local/carma \ - && mkdir build \ - && cd build \ - && cmake -DCARMA_INSTALL_LIB=ON .. \ - && cmake --build . --config Release --target install \ - && rm -rf /usr/local/carma + && rm -rf /usr/local/carma/.git \ + && cd /usr/local/carma \ + && mkdir build \ + && cd build \ + && cmake -DCARMA_INSTALL_LIB=ON .. \ + && cmake --build . --config Release --target install \ + && rm -rf /usr/local/carma # Install Python COPY package_lists/python_packages.txt /package_lists/python_packages.txt RUN apt-get update &&\ - apt-get -y --no-install-recommends install \ - python3-pip \ - python3-dev && \ - # Python packages - pip3 install -U --no-cache-dir \ - $(grep -o '^[^#]*' package_lists/python_packages.txt | tr '\n' ' ') \ - && apt-get autoclean -y \ - && rm -rf /var/lib/apt/lists/* + apt-get -y --no-install-recommends install \ + python3-pip \ + python3-dev \ + python3-venv && \ + # Python packages + pip3 install -U --no-cache-dir \ + $(grep -o '^[^#]*' package_lists/python_packages.txt | tr '\n' ' ') \ + && apt-get autoclean -y \ + && rm -rf /var/lib/apt/lists/* # Set PATH for user installed python packages ENV PATH="/home/vscode/.local/bin:${PATH}" @@ -127,31 +129,31 @@ COPY install_scripts/install_latex.sh /install_scripts/install_latex.sh COPY package_lists/latex_packages.txt /package_lists/latex_packages.txt RUN chmod +x install_scripts/install_latex.sh &&\ - install_scripts/install_latex.sh \ - && export PATH="/usr/local/texlive/bin/x86_64-linux:${PATH}" \ - && tlmgr option -- autobackup 0 \ - && tlmgr option -- docfiles 0 \ - && tlmgr option -- srcfiles 0 \ - && tlmgr install \ - $(grep -o '^[^#]*' package_lists/latex_packages.txt | tr '\n' ' ') \ - && chown --recursive $USERNAME:$USERNAME /usr/local/texlive + install_scripts/install_latex.sh \ + && export PATH="/usr/local/texlive/bin/x86_64-linux:${PATH}" \ + && tlmgr option -- autobackup 0 \ + && tlmgr option -- docfiles 0 \ + && tlmgr option -- srcfiles 0 \ + && tlmgr install \ + $(grep -o '^[^#]*' package_lists/latex_packages.txt | tr '\n' ' ') \ + && chown --recursive $USERNAME:$USERNAME /usr/local/texlive # Set Latex Path ENV PATH="/usr/local/texlive/bin/x86_64-linux:${PATH}" # Install R -ENV R_VERSION=4.3.3 +ENV R_VERSION=4.4.1 # Set RSPM snapshot see: # https://packagemanager.posit.co/client/#/repos/cran/setup?r_environment=other&snapshot=2023-10-04&distribution=ubuntu-22.04 -ENV R_REPOS=https://packagemanager.posit.co/cran/__linux__/jammy/2024-03-21 +ENV R_REPOS=https://packagemanager.posit.co/cran/__linux__/jammy/2024-07-14 COPY install_scripts/install_r.sh /install_scripts/install_r.sh COPY package_lists/r_packages.txt /package_lists/r_packages.txt COPY package_lists/r_packages_github.txt /package_lists/r_packages_github.txt RUN chmod +x install_scripts/install_r.sh &&\ - install_scripts/install_r.sh + install_scripts/install_r.sh COPY --chown=$USERNAME .misc/.zshrc /home/$USERNAME/. diff --git a/install_scripts/install_latex.sh b/install_scripts/install_latex.sh index 94cc798..04d0190 100644 --- a/install_scripts/install_latex.sh +++ b/install_scripts/install_latex.sh @@ -3,8 +3,7 @@ # Install build dependencies apt-get update apt-get install -y --no-install-recommends \ -wget \ -pandoc +wget # Install Latex wget http://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz diff --git a/install_scripts/install_r.sh b/install_scripts/install_r.sh index f4ee00a..41089b2 100644 --- a/install_scripts/install_r.sh +++ b/install_scripts/install_r.sh @@ -17,7 +17,6 @@ RUNDEPS="ca-certificates \ vim-tiny \ wget \ dirmngr \ - pandoc \ libmagick++-dev \ libpoppler-cpp-dev \ libudunits2-dev \ diff --git a/package_lists/latex_packages.txt b/package_lists/latex_packages.txt index b6b5ea2..6b797e1 100644 --- a/package_lists/latex_packages.txt +++ b/package_lists/latex_packages.txt @@ -57,6 +57,8 @@ ieeetran ifoddpage inconsolata koma-script +l3backend +l3backend-dev latexindent # Indentation latexmk latex-tools-dev @@ -99,9 +101,11 @@ textpos threeparttable threeparttablex thumbpdf +titlesec #! To find packages: tlmgr search --global --file "authblk.sty" tracklang ulem +upquote varwidth was wrapfig diff --git a/package_lists/python_packages.txt b/package_lists/python_packages.txt index 7c8ff0e..235bffe 100644 --- a/package_lists/python_packages.txt +++ b/package_lists/python_packages.txt @@ -1,12 +1,15 @@ aiofiles autopep8 +black bspline +build celery fastapi flower google-api-python-client google-auth-httplib2 google-auth-oauthlib +h5py investiny investpy ipykernel @@ -14,9 +17,11 @@ Jinja2 kaleido matplotlib meteostat +mysql mysqlclient nbclient nbformat +numba numdifftools numpy pandas @@ -28,9 +33,14 @@ pyparsing==2.4.7 pytest redis requests +ruff scikit-learn scipy +scoringrules +setuptools sqlalchemy +sstudentt statsmodels tdqm +tqdm uvicorn diff --git a/package_lists/r_packages.txt b/package_lists/r_packages.txt index d10d249..f517b6e 100644 --- a/package_lists/r_packages.txt +++ b/package_lists/r_packages.txt @@ -7,6 +7,7 @@ cli conflicted copula corrplot +covr cowplot crayon crosstalk @@ -17,6 +18,7 @@ devtools DiceKriging doParallel doSNOW +DT energy eurostat evir @@ -47,6 +49,7 @@ gridSVG grImport2 gt Hmisc +htmltools htmlwidgets igraph inline