From 4799b327d2b28aa0cb89d01259206c75f5a3fd8f Mon Sep 17 00:00:00 2001 From: Martin Gruner Date: Wed, 4 May 2022 17:39:02 +0200 Subject: [PATCH] Switch to Node.js 16 from Nodesource as that will be a dependency of Zammad 5.2 soon. (#279) * Switch to Node.js 16 from Nodesource as that will be a dependency of Zammad 5.2 soon. * Fixed indentation. --- containers/zammad/Dockerfile | 2 +- containers/zammad/setup.sh | 18 +++++++++++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/containers/zammad/Dockerfile b/containers/zammad/Dockerfile index 5e3456e..369ca9d 100644 --- a/containers/zammad/Dockerfile +++ b/containers/zammad/Dockerfile @@ -37,7 +37,7 @@ LABEL org.label-schema.build-date="$BUILD_DATE" \ org.label-schema.vcs-url="https://github.com/zammad/zammad" \ org.label-schema.vcs-type="Git" \ org.label-schema.vendor="Zammad" \ - org.label-schema.schema-version="5.1.0" \ + org.label-schema.schema-version="5.1.0" \ org.label-schema.docker.cmd="sysctl -w vm.max_map_count=262144;docker-compose up" ENV GIT_BRANCH stable diff --git a/containers/zammad/setup.sh b/containers/zammad/setup.sh index d90caf6..9b5de47 100755 --- a/containers/zammad/setup.sh +++ b/containers/zammad/setup.sh @@ -3,7 +3,7 @@ set -e # install dependencies if [ "$1" = 'builder' ]; then - PACKAGES="build-essential curl git libimlib2-dev libpq-dev nodejs shared-mime-info" + PACKAGES="build-essential curl git libimlib2-dev libpq-dev shared-mime-info" elif [ "$1" = 'runner' ]; then PACKAGES="curl libimlib2 libpq5 nginx rsync" fi @@ -12,6 +12,22 @@ apt-get update apt-get upgrade -y # shellcheck disable=SC2086 apt-get install -y --no-install-recommends ${PACKAGES} + +if [ "$1" = 'builder' ]; then + # Install Node.js 16 repository from Nodesource + apt-get --no-install-recommends -y install gnupg + KEYRING=/usr/share/keyrings/nodesource.gpg + curl -fsSL https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor | tee "$KEYRING" >/dev/null + cat - > /etc/apt/sources.list.d/nodesource.list <