Add Debian Bookworm images

This commit is contained in:
Clemens Beck 2024-01-18 10:20:04 +00:00 committed by Balasankar 'Balu' C
parent 5cc9de6b26
commit db6f2daec2
10 changed files with 55 additions and 24 deletions

View file

@ -70,7 +70,7 @@
parallel: parallel:
matrix: matrix:
- BUILD_OS: debian - BUILD_OS: debian
OS_VERSION: bullseye OS_VERSION: [bullseye, bookworm]
NOTIFY_VERSION_UPDATE: "true" NOTIFY_VERSION_UPDATE: "true"
before_script: before_script:
- !reference [.install-qemu, before_script] - !reference [.install-qemu, before_script]

View file

@ -20,11 +20,10 @@
e2e: e2e:
extends: extends:
- .e2e - .e2e
variables:
OS: "debian:bullseye"
parallel: parallel:
matrix: matrix:
- RUBY: ['3.0', '3.1', '3.2'] - OS: ["debian:bullseye", "debian:bookworm"]
RUBY: ['3.0', '3.1', '3.2']
BUNDLER: ['2.4', '2.5'] BUNDLER: ['2.4', '2.5']
# Image with ruby, bundler and docker # Image with ruby, bundler and docker
@ -40,7 +39,8 @@ e2e-chrome:
- e2e-docker - e2e-docker
parallel: parallel:
matrix: matrix:
- RUBY: ['3.0', '3.1', '3.2'] - OS: ["debian:bullseye", "debian:bookworm"]
RUBY: ['3.0', '3.1', '3.2']
BUNDLER: ['2.4', '2.5'] BUNDLER: ['2.4', '2.5']
CHROME: ['119', '120'] CHROME: ['119', '120']

View file

@ -17,7 +17,7 @@ gitaly:
stage: gitaly stage: gitaly
parallel: parallel:
matrix: matrix:
- OS: ['debian:bullseye'] - OS: ['debian:bullseye', 'debian:bookworm']
GOLANG: ['1.19', '1.20', '1.21'] GOLANG: ['1.19', '1.20', '1.21']
RUST: ['1.73'] RUST: ['1.73']
GIT: ['2.36'] GIT: ['2.36']

View file

@ -36,15 +36,15 @@ gitlab:
YARN: '1.22' YARN: '1.22'
GRAPHICSMAGICK: '1.3.36' GRAPHICSMAGICK: '1.3.36'
ARCH: linux/amd64,linux/arm64 ARCH: linux/amd64,linux/arm64
GIT: '2.36'
RUST: '1.73'
NODE: '18.17'
parallel: parallel:
matrix: matrix:
- OS: ['debian:bullseye', 'debian:bullseye-slim'] - OS: ['debian:bullseye', 'debian:bullseye-slim', 'debian:bookworm', 'debian:bookworm-slim']
RUBY: ['3.0.patched', '3.1.patched', '3.2.patched'] RUBY: ['3.0.patched', '3.1.patched', '3.2.patched']
GIT: ['2.36'] POSTGRESQL: ['13', '14', '15']
POSTGRESQL: ['12', '13', '14', '15'] GOLANG: ['1.20', '1.21']
GOLANG: ['1.19', '1.20', '1.21']
RUST: ['1.73']
NODE: ['18.17']
CHROME: ['119', '120'] CHROME: ['119', '120']
# Used by GitLab's compile-production-assets and compile-test-assets jobs # Used by GitLab's compile-production-assets and compile-test-assets jobs
@ -60,7 +60,7 @@ gitlab-assets:
ARCH: amd64,arm64 ARCH: amd64,arm64
parallel: parallel:
matrix: matrix:
- OS: ['debian:bullseye'] - OS: ['debian:bullseye', 'debian:bookworm']
RUBY: ['3.0', '3.1', '3.2'] RUBY: ['3.0', '3.1', '3.2']
GIT: ['2.33'] GIT: ['2.33']
NODE: ['18.17'] NODE: ['18.17']
@ -81,11 +81,10 @@ gitlab-slim-ruby:
extends: extends:
- .gitlab - .gitlab
stage: gitlab stage: gitlab
variables:
OS: 'debian:bullseye-slim'
parallel: parallel:
matrix: matrix:
- RUBY: ['3.0', '3.1', '3.2'] - RUBY: ['3.0', '3.1', '3.2']
OS: ['debian:bullseye-slim', 'debian:bookworm-slim']
# Used by GitLab's workhorse tests # Used by GitLab's workhorse tests
gitlab-workhorse: gitlab-workhorse:
@ -98,7 +97,7 @@ gitlab-workhorse:
RUBYGEMS: '3.4' RUBYGEMS: '3.4'
parallel: parallel:
matrix: matrix:
- OS: ['debian:bullseye'] - OS: ['debian:bullseye', 'debian:bookworm']
RUBY: ['3.0', '3.1', '3.2'] RUBY: ['3.0', '3.1', '3.2']
GOLANG: ['1.19', '1.20', '1.21'] GOLANG: ['1.19', '1.20', '1.21']
RUST: ['1.73'] RUST: ['1.73']

View file

@ -1,6 +1,6 @@
# Save amd64 chrome and arm64 .deb files to package registry # Save amd64 chrome and arm64 .deb files to package registry
ARG BUILD_OS=debian ARG BUILD_OS=debian
ARG OS_VERSION=bullseye ARG OS_VERSION=bookworm
FROM ${BUILD_OS}:${OS_VERSION} FROM ${BUILD_OS}:${OS_VERSION}
ARG TARGETARCH ARG TARGETARCH

View file

@ -97,7 +97,7 @@ new_image:
extends: extends:
- .build_dynamic_image - .build_dynamic_image
variables: variables:
OS: 'debian:bullseye' OS: 'debian:bookworm'
RUBY: '3.0' RUBY: '3.0'
GOLANG: '1.15' GOLANG: '1.15'
RUST: '1.73.0' RUST: '1.73.0'

View file

@ -75,7 +75,7 @@ function build_ubi() {
} }
BUILD_OS=${BUILD_OS:-debian} BUILD_OS=${BUILD_OS:-debian}
OS_VERSION=${OS_VERSION:-bullseye} OS_VERSION=${OS_VERSION:-bookworm}
# When using a -slim version, actually use the non-slim OS version. # When using a -slim version, actually use the non-slim OS version.
# #

View file

@ -18,6 +18,18 @@ function install_debian_bullseye_deps() {
libre2-dev libevent-dev gettext rsync git-core lsb-release libre2-dev libevent-dev gettext rsync git-core lsb-release
} }
function install_debian_bookworm_deps() {
apt-get install -y \
curl wget build-essential apt-utils clang locales openssh-client \
libclang-dev libssl-dev libyaml-dev libreadline-dev llvm-dev zlib1g-dev \
libncurses5-dev libffi-dev ca-certificates libxml2-dev \
libxslt1-dev libcurl4-openssl-dev libicu-dev \
logrotate python3-docutils pkg-config cmake \
libkrb5-dev postgresql-client unzip \
libsqlite3-dev libpq-dev libpng-dev libjpeg-dev libzstd-dev \
libre2-dev libevent-dev gettext rsync git-core lsb-release
}
function prepare_debian_environment() { function prepare_debian_environment() {
export DEBIAN_FRONTEND=noninteractive export DEBIAN_FRONTEND=noninteractive
@ -27,8 +39,9 @@ function prepare_debian_environment() {
case "$VERSION" in case "$VERSION" in
11) 11)
install_debian_bullseye_deps install_debian_bullseye_deps;;
;; 12)
install_debian_bookworm_deps;;
esac esac
# Set UTF-8 # Set UTF-8

View file

@ -16,6 +16,10 @@ JEMALLOC_DOWNLOAD_URL="https://github.com/jemalloc/jemalloc/releases/download/${
BUNDLER_VERSION=${3:-""} BUNDLER_VERSION=${3:-""}
RUBYGEMS_VERSION=${4:-""} RUBYGEMS_VERSION=${4:-""}
# only installed for Ruby 3.0 on debian bookworm
CUSTOM_OPENSSL_VERSION=1.1.1w
CUSTOM_OPENSSL_DIR=/usr/local/openssl_ruby
function build_common() { function build_common() {
# Download jemalloc # Download jemalloc
mkdir -p /usr/src/jemalloc mkdir -p /usr/src/jemalloc
@ -90,6 +94,7 @@ function build_debian() {
apt-get update apt-get update
apt-get install -y --no-install-recommends bison dpkg-dev libgdbm-dev autoconf apt-get install -y --no-install-recommends bison dpkg-dev libgdbm-dev autoconf
install_custom_openssl_if_needed
build_common build_common
apt-get purge -y --auto-remove ruby apt-get purge -y --auto-remove ruby
@ -115,6 +120,20 @@ function build_ubi() {
[ "$(command -v ruby)" = '/usr/local/bin/ruby' ] [ "$(command -v ruby)" = '/usr/local/bin/ruby' ]
} }
function install_custom_openssl_if_needed() {
if [[ $RUBY_VERSION =~ "3.0" ]] && [[ $OS_VERSION =~ "bookworm" ]]; then
apt-get install -y --no-install-recommends perl make gcc
curl -fsSL "https://www.openssl.org/source/openssl-${CUSTOM_OPENSSL_VERSION}.tar.gz" | tar -xzC /tmp
cd /tmp/openssl-${CUSTOM_OPENSSL_VERSION}
./config --prefix="$CUSTOM_OPENSSL_DIR" --openssldir="$CUSTOM_OPENSSL_DIR" shared zlib
make
make install
rm -rf /tmp/openssl-${CUSTOM_OPENSSL_VERSION}
# set CONFIGURE_ARGS for ruby builds
export CONFIGURE_ARGS="${CONFIGURE_ARGS:-} --with-openssl-dir=$CUSTOM_OPENSSL_DIR"
fi
}
BUILD_OS=${BUILD_OS:-debian} BUILD_OS=${BUILD_OS:-debian}
if [[ $BUILD_OS =~ debian ]]; then if [[ $BUILD_OS =~ debian ]]; then

View file

@ -93,8 +93,8 @@ function print_chrome_args() {
CHROMIUM_VERSION=119.0.6045.159-1 CHROMIUM_VERSION=119.0.6045.159-1
;; ;;
120|120.0) 120|120.0)
CHROME_VERSION=120.0.6099.199-1 CHROME_VERSION=120.0.6099.216-1
CHROMIUM_VERSION=120.0.6099.199-1 CHROMIUM_VERSION=120.0.6099.216-1
;; ;;
*) fail "Unknown chrome version $1" ;; *) fail "Unknown chrome version $1" ;;
esac esac
@ -417,7 +417,7 @@ if [[ -n "$OS" ]]; then
elif [[ -n "$UBI" ]]; then elif [[ -n "$UBI" ]]; then
unset DEBIAN unset DEBIAN
else else
DEBIAN=${DEBIAN:-bullseye} DEBIAN=${DEBIAN:-bookworm}
fi fi
build_custom_if_needed $@ build_custom_if_needed $@