From 622cdd625926b3a290eeb4bfee62e865b7c860f8 Mon Sep 17 00:00:00 2001 From: nicobo Date: Sun, 4 Oct 2020 16:05:44 +0200 Subject: [PATCH] Fixes nextcloud/docker#1088 Signed-off-by: nicobo --- docker-entrypoint.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-entrypoint.sh b/docker-entrypoint.sh index b9ec5fc5..e7e4e302 100755 --- a/docker-entrypoint.sh +++ b/docker-entrypoint.sh @@ -27,8 +27,8 @@ file_env() { local var="$1" local fileVar="${var}_FILE" local def="${2:-}" - local varValue=$(env | grep -E "^${var}=" | sed -E -e "s/^${var}=//") - local fileVarValue=$(env | grep -E "^${fileVar}=" | sed -E -e "s/^${fileVar}=//") + local varValue="`env | grep -E \"^${var}=\" | sed -E -e \"s/^${var}=//\"`" + local fileVarValue="`env | grep -E \"^${fileVar}=\" | sed -E -e \"s/^${fileVar}=//\"`" if [ -n "${varValue}" ] && [ -n "${fileVarValue}" ]; then echo >&2 "error: both $var and $fileVar are set (but are exclusive)" exit 1