mirror of
https://github.com/zokradonh/kopano-docker.git
synced 2026-08-21 21:33:02 +00:00
cut quotes from additional package var earlier on (#224)
* cut quotes from additional package var earlier on * add easy debugging switch to script and predefine env var in base image
This commit is contained in:
+3
-1
@@ -6,12 +6,14 @@ KCCONF_SERVERPORT=${KCCONF_SERVERPORT:-236}
|
||||
ADDITIONAL_KOPANO_PACKAGES=${ADDITIONAL_KOPANO_PACKAGES:-""}
|
||||
|
||||
set -eu # unset variables are errors & non-zero return values exit the whole script
|
||||
[ "$DEBUG" ] && set -x
|
||||
|
||||
ADDITIONAL_KOPANO_PACKAGES=$(echo "$ADDITIONAL_KOPANO_PACKAGES" | tr -d '"')
|
||||
[ -n "${ADDITIONAL_KOPANO_PACKAGES// }" ] && apt update
|
||||
[ -n "${ADDITIONAL_KOPANO_PACKAGES// }" ] && for installpkg in $ADDITIONAL_KOPANO_PACKAGES; do
|
||||
# shellcheck disable=SC2016 disable=SC2086
|
||||
if [ "$(dpkg-query -W -f='${Status}' $installpkg 2>/dev/null | grep -c 'ok installed')" -eq 0 ]; then
|
||||
apt --assume-yes install "$installpkg"
|
||||
apt --assume-yes --no-upgrade install "$installpkg"
|
||||
fi
|
||||
done
|
||||
|
||||
|
||||
Reference in New Issue
Block a user