This is an automated email from the ASF dual-hosted git repository.

ronny pushed a commit to branch add-bookworm
in repository https://gitbox.apache.org/repos/asf/couchdb-ci.git

commit a2203c7c84bfc8995412daebfc55f7f4c555b125
Author: Ronny Berndt <ro...@apache.org>
AuthorDate: Wed Nov 1 14:33:33 2023 +0100

    Add Debian Bookworm
---
 bin/apt-dependencies.sh     | 18 ++++----------
 dockerfiles/debian-bookworm | 60 +++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 65 insertions(+), 13 deletions(-)

diff --git a/bin/apt-dependencies.sh b/bin/apt-dependencies.sh
index a1b611a..0b5d7b6 100755
--- a/bin/apt-dependencies.sh
+++ b/bin/apt-dependencies.sh
@@ -42,7 +42,7 @@ apt-get update && apt-get install --no-install-recommends -y 
lsb-release
 SCRIPTPATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
 . ${SCRIPTPATH}/detect-arch.sh >/dev/null
 . ${SCRIPTPATH}/detect-os.sh >/dev/null
-debians='(jessie|buster)'
+debians='(buster|bullseye|bookworm)'
 ubuntus='(bionic|focal|jammy)'
 echo "Detected Ubuntu/Debian version: ${VERSION_CODENAME}   arch: ${ARCH}"
 
@@ -67,8 +67,7 @@ apt-get install --no-install-recommends -y 
apt-transport-https curl git pkg-conf
     sudo wget zip unzip \
     build-essential ca-certificates libcurl4-openssl-dev \
     libicu-dev libnspr4-dev \
-    help2man python3-sphinx \
-    curl debhelper devscripts dh-exec dh-python equivs \
+    help2man curl debhelper devscripts dh-exec dh-python equivs \
     dialog equivs lintian libwww-perl quilt \
     reprepro rsync \
     vim-tiny screen procps dirmngr ssh-client
@@ -172,6 +171,9 @@ if [ "$1" != "nojs" ]; then
   if [ "${VERSION_CODENAME}" == "bullseye" ]; then
     apt-get install --no-install-recommends -y libmozjs-78-dev
   fi
+  if [ "${VERSION_CODENAME}" == "bookworm" ]; then
+      apt-get install --no-install-recommends -y libmozjs-78-dev 
libmozjs-102-dev
+  fi
 else
   # install js build-time dependencies only
   # we can't add the CouchDB repo here because the plat may not exist yet
@@ -180,15 +182,5 @@ fi
 
 # Erlang is installed by apt-erlang.sh
 
-# FoundationDB - but only for amd64 right now!!!!
-if [ "${ARCH}" == "x86_64" ]; then
-  wget 
https://github.com/apple/foundationdb/releases/download/6.3.23/foundationdb-clients_6.3.23-1_amd64.deb
-  wget 
https://github.com/apple/foundationdb/releases/download/6.3.23/foundationdb-server_6.3.23-1_amd64.deb
-  dpkg -i ./foundationdb*deb
-  pkill -f fdb || true
-  pkill -f foundation || true
-  rm -rf ./foundationdb*deb
-fi
-
 # clean up
 apt-get clean
diff --git a/dockerfiles/debian-bookworm b/dockerfiles/debian-bookworm
new file mode 100644
index 0000000..9022c0d
--- /dev/null
+++ b/dockerfiles/debian-bookworm
@@ -0,0 +1,60 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+#   Unless required by applicable law or agreed to in writing,
+#   software distributed under the License is distributed on an
+#   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#   KIND, either express or implied.  See the License for the
+#   specific language governing permissions and limitations
+
+# NOTE: These are intended to be built using the arguments as
+# described in ../build.sh. See that script for more details.
+
+ARG repository=debian
+
+FROM $repository:bookworm
+
+# Choose whether to install SpiderMonkey 1.8.5, default yes
+ARG js=js
+# Choose whether to install Erlang, default yes
+ARG erlang=erlang
+# Select version of Node, Erlang and Elixir
+ARG erlangversion=24.3.4.14
+ARG kerlversions=24.3.4.14,25.3.2.7,26.1.2
+ARG elixirversion=v1.15.7
+ARG nodeversion=18
+
+# Create Jenkins user and group
+RUN groupadd --gid 910 jenkins; \
+  useradd --uid 910 --gid jenkins --create-home jenkins
+
+# Copy couchdb-ci repo into root's home directory
+ADD --chown=root:root bin /root/couchdb-ci/bin/
+ADD --chown=root:root files /root/couchdb-ci/files/
+
+# Jenkins builds in /usr/src/couchdb.
+RUN mkdir -p /usr/src/couchdb; \
+  chown -R jenkins:jenkins /usr/src/couchdb
+
+# Install all dependencies, and optionally SM 1.8.5
+# This allows us to use the same Dockerfile for building SM
+RUN ERLANGVERSION=$erlangversion \
+  KERLVERSIONS=$kerlversions \
+  ELIXIRVERSION=$elixirversion \
+  NODEVERSION=$nodeversion \
+  /root/couchdb-ci/bin/install-dependencies.sh $js $erlang
+
+# Allow Jenkins to sudo
+RUN echo "jenkins ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/jenkins
+
+USER jenkins
+
+# overwrite this with 'CMD []' in a dependent Dockerfile
+CMD ["/bin/bash"]

Reply via email to