Add Ruby 2.7 images for GitLab CE/EE images

Ruby 2.7.1 is only available on Debian Buster, so we have to upgrade
from Debian Stretch.

Fix install-essentials for Debian 10 (Buster):

1. MySQL client is no longer needed
2. Yank libgdbm3 and libgdbm-dev because it's not clear why it's needed
3. Pull legacy nodejs from Debian Buster builds since Node 12.x conflicted
This commit is contained in:
Stan Hu 2020-08-04 10:39:48 -07:00
parent 25174a3ef3
commit a7a13a87d6
3 changed files with 41 additions and 11 deletions

View file

@ -213,9 +213,17 @@ function parse_arguments() {
read base
read base_version
# Lock Ruby to Debian stretch
# Lock Ruby to Debian version to pin OpenSSL version
case "$base" in
ruby) base_version="$base_version-stretch" ;;
ruby)
case "$base_version" in
2.6.*)
base_version="$base_version-stretch"
;;
*)
base_version="$base_version-buster"
;;
esac
esac
printf -- "-f Dockerfile.custom " "$base"

View file

@ -6,15 +6,31 @@ IFS=$'\n\t'
export DEBIAN_FRONTEND=noninteractive
apt-get update
apt-get install -y \
curl wget build-essential apt-utils locales \
libssl-dev libyaml-dev libreadline6-dev zlib1g-dev \
libncurses5-dev libffi-dev libgdbm3 libgdbm-dev \
ca-certificates libyaml-dev checkinstall libxml2-dev \
libxslt-dev libcurl4-openssl-dev libicu-dev \
logrotate python-docutils pkg-config cmake nodejs \
libkrb5-dev postgresql-client mysql-client unzip \
libre2-dev gettext rsync \
EXIT_CODE=0
grep "Debian GNU/Linux 9" /etc/issue || EXIT_CODE=$?
if [ $EXIT_CODE -eq 0 ]
then
apt-get install -y \
curl wget build-essential apt-utils locales \
libssl-dev libyaml-dev libreadline6-dev zlib1g-dev \
libncurses5-dev libffi-dev libgdbm3 libgdbm-dev \
ca-certificates libyaml-dev checkinstall libxml2-dev \
libxslt-dev libcurl4-openssl-dev libicu-dev \
logrotate python-docutils pkg-config cmake nodejs \
libkrb5-dev postgresql-client mysql-client unzip \
libre2-dev gettext rsync
else
apt-get install -y \
curl wget build-essential apt-utils locales \
libssl-dev libyaml-dev libreadline-dev zlib1g-dev \
libncurses5-dev libffi-dev ca-certificates libyaml-dev libxml2-dev \
libxslt1-dev libcurl4-openssl-dev libicu-dev \
logrotate python-docutils pkg-config cmake \
libkrb5-dev postgresql-client unzip \
libre2-dev gettext rsync
fi
# Set UTF-8
# http://stackoverflow.com/a/3182519/2137281