2023-06-10 15:05:21 +00:00
|
|
|
FROM debian:bookworm
|
2020-02-02 21:06:11 +00:00
|
|
|
|
|
|
|
RUN DEBIAN_FRONTEND=noninteractive apt-get update
|
|
|
|
RUN DEBIAN_FRONTEND=noninteractive apt-get upgrade -y
|
2020-03-31 19:54:28 +00:00
|
|
|
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y wget gpg
|
|
|
|
|
2024-08-13 17:59:45 +00:00
|
|
|
RUN echo "deb http://deb.debian.org/debian/ bookworm main contrib non-free" > /etc/apt/sources.list && \
|
|
|
|
echo "deb http://security.debian.org/debian-security bookworm-security main" >> /etc/apt/sources.list && \
|
|
|
|
echo "deb http://deb.debian.org/debian/ bookworm-updates main contrib non-free" >> /etc/apt/sources.list
|
2020-03-31 19:54:28 +00:00
|
|
|
|
2021-02-07 00:05:27 +00:00
|
|
|
RUN DEBIAN_FRONTEND=noninteractive apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y locales libffi-dev \
|
2020-02-02 21:06:11 +00:00
|
|
|
libssl-dev default-libmysqlclient-dev ca-certificates libpq-dev libjpeg62 libjpeg-dev \
|
|
|
|
libpng-dev libpng-dev build-essential git mercurial build-essential \
|
|
|
|
libbz2-dev libsqlite3-dev libreadline-dev zlib1g-dev libncurses5-dev \
|
2021-02-07 00:05:27 +00:00
|
|
|
libgdbm-dev libgd-dev cron git subversion vim nano mc htop procps \
|
|
|
|
dropbear gettext wget redis-server memcached supervisor curl ssh \
|
2024-08-13 17:59:45 +00:00
|
|
|
mariadb-client postgresql-client-15 postgresql-15-postgis-3-scripts bind9-host dnsutils nginx nginx-extras libnginx-mod-http-image-filter \
|
2020-02-02 21:06:11 +00:00
|
|
|
libxml2-dev libxslt1-dev openssh-sftp-server links2 lynx \
|
2021-02-07 00:05:27 +00:00
|
|
|
imagemagick libmagick++-6.q16-dev libmagick++-6.q16hdri-dev libmagickwand-dev ncdu libsodium-dev \
|
|
|
|
python3 python3-pip python3-virtualenv \
|
2024-08-13 17:59:45 +00:00
|
|
|
libcurl4-openssl-dev python3-dev libproj-dev gdal-bin libmemcached-dev swig mutt \
|
2021-02-07 00:05:27 +00:00
|
|
|
ffmpeg libyaml-dev libc-client2007e-dev libonig-dev libkrb5-dev dialog \
|
|
|
|
whiptail tmux rsync nmap libzip-dev libfreetype6-dev \
|
2024-08-13 17:59:45 +00:00
|
|
|
jpegoptim optipng pngquant gifsicle webp libvpx-dev libwebp-dev jq inotify-tools ripgrep \
|
|
|
|
wkhtmltopdf libzbar0 fzf
|
|
|
|
|
|
|
|
# This is stange thing in Debian 12, it blocks installation of chromium
|
|
|
|
RUN DEBIAN_FRONTEND=noninteractive apt-get remove -y luit
|
|
|
|
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y chromium
|
2021-02-07 00:05:27 +00:00
|
|
|
|
2020-02-02 21:06:11 +00:00
|
|
|
WORKDIR /srv
|
|
|
|
|
|
|
|
RUN useradd -d /srv app -s /bin/bash
|
|
|
|
RUN usermod -G crontab -a app
|
|
|
|
RUN rm /etc/localtime
|
|
|
|
RUN ln -s /usr/share/zoneinfo/Europe/Prague /etc/localtime
|
|
|
|
|
|
|
|
ADD /etc/locale.gen /etc/
|
|
|
|
RUN locale-gen
|
|
|
|
ENV LANG en_US.UTF-8
|
|
|
|
ENV LC_ALL en_US.UTF-8
|
|
|
|
|
|
|
|
ENV TERM xterm
|
|
|
|
|
|
|
|
#############
|
|
|
|
# Techs
|
|
|
|
#############
|
|
|
|
|
|
|
|
## Node.js
|
2024-08-13 17:59:45 +00:00
|
|
|
# From https://nodejs.org/en/about/previous-releases
|
2020-02-02 21:06:11 +00:00
|
|
|
WORKDIR /usr/src
|
|
|
|
ADD build_node.sh /usr/local/bin/build_node.sh
|
2024-08-13 17:59:45 +00:00
|
|
|
RUN build_node.sh 18.20.4
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_node.sh 20.18.0
|
2024-08-13 17:59:45 +00:00
|
|
|
RUN build_node.sh 21.7.3
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_node.sh 22.9.0
|
2020-02-02 21:06:11 +00:00
|
|
|
|
|
|
|
## Python
|
2024-08-13 17:59:45 +00:00
|
|
|
# https://www.python.org/downloads/
|
2020-02-02 21:06:11 +00:00
|
|
|
WORKDIR /usr/src
|
|
|
|
ADD build_python.sh /usr/local/bin/build_python.sh
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_python.sh 3.11.10
|
|
|
|
RUN build_python.sh 3.12.7
|
|
|
|
RUN build_python.sh 3.13.0
|
2020-02-02 21:06:11 +00:00
|
|
|
|
2021-03-05 23:39:20 +00:00
|
|
|
## PHP 8
|
2024-08-13 17:59:45 +00:00
|
|
|
# https://www.php.net/downloads.php
|
2021-03-07 23:27:45 +00:00
|
|
|
ADD build_php8.sh /usr/local/bin/build_php8.sh
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_php8.sh 8.2.24
|
|
|
|
RUN build_php8.sh 8.3.12
|
2021-03-05 23:39:20 +00:00
|
|
|
|
2021-02-07 00:05:27 +00:00
|
|
|
## Ruby
|
2024-08-13 17:59:45 +00:00
|
|
|
# https://www.ruby-lang.org/en/downloads/releases/
|
2021-02-07 00:05:27 +00:00
|
|
|
WORKDIR /usr/src
|
|
|
|
ADD build_ruby.sh /usr/local/bin/build_ruby.sh
|
2024-08-13 17:59:45 +00:00
|
|
|
RUN build_ruby.sh 3.2.5
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_ruby.sh 3.3.5
|
2020-02-02 21:06:11 +00:00
|
|
|
|
2021-02-07 00:05:27 +00:00
|
|
|
## Deno
|
2024-08-13 17:59:45 +00:00
|
|
|
# From: https://github.com/denoland/deno/releases
|
2021-02-07 00:05:27 +00:00
|
|
|
ADD build_deno.sh /usr/local/bin/build_deno.sh
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_deno.sh 1.46.3
|
2024-08-13 17:59:45 +00:00
|
|
|
|
|
|
|
# Bun
|
|
|
|
# From here: https://bun.sh/
|
|
|
|
ADD build_bun.sh /usr/local/bin/build_bun.sh
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_bun.sh 1.1.29
|
2024-08-13 17:59:45 +00:00
|
|
|
|
|
|
|
# OpenJDK
|
|
|
|
# From here: https://jdk.java.net/
|
|
|
|
ADD build_openjdk.sh /usr/local/bin/build_openjdk.sh
|
2024-10-08 09:13:35 +00:00
|
|
|
# RUN build_openjdk.sh 22.0.2 c9ecb94cd31b495da20a27d4581645e8 9
|
|
|
|
RUN build_openjdk.sh 23 3c5b90190c68498b986a97f276efd28a 37
|
2024-08-13 17:59:45 +00:00
|
|
|
|
|
|
|
# Golang
|
|
|
|
# From here: https://go.dev/dl/
|
|
|
|
ADD build_golang.sh /usr/local/bin/build_golang.sh
|
2024-10-08 09:13:35 +00:00
|
|
|
RUN build_golang.sh 1.23.2
|
2024-08-13 17:59:45 +00:00
|
|
|
|
|
|
|
|
|
|
|
#############
|
|
|
|
|
|
|
|
# WKHTMLTOX This is not in development anymore so we will remove it with next version of Debian
|
|
|
|
|
|
|
|
WORKDIR /usr/src
|
|
|
|
RUN apt install -f xfonts-75dpi && \
|
|
|
|
wget https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6.1-3/wkhtmltox_0.12.6.1-3.bookworm_amd64.deb && \
|
|
|
|
dpkg -i wkhtmltox_0.12.6.1-3.bookworm_amd64.deb && \
|
|
|
|
rm wkhtmltox_0.12.6.1-3.bookworm_amd64.deb
|
2020-02-02 21:06:11 +00:00
|
|
|
|
|
|
|
#############
|
|
|
|
|
|
|
|
## Support tools and miscellaneous stuff
|
|
|
|
|
|
|
|
RUN rm -f /etc/cron.d/* /etc/cron.daily/* /etc/cron.hourly/* /etc/cron.monthly/* /etc/cron.weekly/*
|
|
|
|
|
|
|
|
ADD /scripts/enable_redis.sh /usr/local/bin/enable-redis
|
|
|
|
ADD /scripts/enable_memcached.sh /usr/local/bin/enable-memcached
|
|
|
|
RUN chmod 755 /usr/local/bin/*
|
|
|
|
|
|
|
|
ADD /etc/supervisord.conf /etc/supervisor/supervisord.conf
|
|
|
|
ADD /examples /opt/examples
|
|
|
|
ADD /etc/bashrc_local /opt/etc/bashrc_local
|
|
|
|
ADD /etc/bash_profile /opt/etc/bash_profile
|
|
|
|
ADD /etc/vimrc /opt/etc/vimrc
|
|
|
|
RUN mkdir -p /opt/etc/bashrc
|
|
|
|
RUN mkdir -p /opt/etc/appinit
|
|
|
|
ADD /etc/bashrc/common.sh /opt/etc/bashrc/
|
|
|
|
ADD /etc/nginx.conf /etc/nginx/nginx.conf
|
|
|
|
|
|
|
|
RUN rmdir /var/lib/nginx
|
|
|
|
RUN ln -s /srv/var/nginx /var/lib/nginx
|
|
|
|
RUN chown app:app /var/log/nginx -R
|
|
|
|
|
|
|
|
RUN chown app:app /home -R
|
|
|
|
|
2021-02-07 00:05:27 +00:00
|
|
|
# Start script
|
|
|
|
|
|
|
|
ADD /start.sh /start.sh
|
|
|
|
RUN chmod 755 /start.sh
|
|
|
|
|
|
|
|
## Roští script
|
|
|
|
|
|
|
|
RUN apt-get install -y fish
|
|
|
|
ADD ./gen_rosti.fish /usr/local/bin/
|
2021-12-03 19:20:43 +00:00
|
|
|
ADD ./rosti.tmpl.sh /usr/src/
|
2021-02-07 00:05:27 +00:00
|
|
|
ADD ./Dockerfile /usr/src/
|
|
|
|
RUN cd /usr/src && /usr/local/bin/gen_rosti.fish > /usr/local/bin/rosti && chmod 755 /usr/local/bin/rosti
|
|
|
|
|
2024-08-13 17:59:45 +00:00
|
|
|
## Rosti tooling
|
|
|
|
|
|
|
|
ADD ./activate_tech.fish /usr/local/bin/activate_tech
|
|
|
|
|
2020-02-02 21:06:11 +00:00
|
|
|
## Cleaning
|
|
|
|
RUN apt-get clean && rm -rf /usr/src/*
|
|
|
|
|
|
|
|
|
|
|
|
VOLUME /srv
|
|
|
|
WORKDIR /srv
|
|
|
|
EXPOSE 8000 22
|
|
|
|
|
|
|
|
ENTRYPOINT ["/start.sh"]
|