From c6e6d3e8eeaa33be64bd5f1384fb61004465b2c2 Mon Sep 17 00:00:00 2001
From: Richard Lea <chigix@zoho.com>
Date: Thu, 23 Apr 2020 16:35:22 +0900
Subject: [PATCH] [Dovecot] fix error redirection at doveconf (#3500)

---
 data/Dockerfiles/dovecot/docker-entrypoint.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/data/Dockerfiles/dovecot/docker-entrypoint.sh b/data/Dockerfiles/dovecot/docker-entrypoint.sh
index 3fd35e3b..77036085 100755
--- a/data/Dockerfiles/dovecot/docker-entrypoint.sh
+++ b/data/Dockerfiles/dovecot/docker-entrypoint.sh
@@ -343,7 +343,7 @@ while [[ ${VERSIONS_OK} != 'OK' ]]; do
     sleep 3
   fi
 done
-PUBKEY_MCRYPT=$(doveconf -P | grep -i mail_crypt_global_public_key 2> /dev/null| cut -d '<' -f2)
+PUBKEY_MCRYPT=$(doveconf -P 2> /dev/null | grep -i mail_crypt_global_public_key | cut -d '<' -f2)
 if [ -f ${PUBKEY_MCRYPT} ]; then
   GUID=$(cat <(echo ${MAILCOW_HOSTNAME}) /mail_crypt/ecpubkey.pem | sha256sum | cut -d ' ' -f1 | tr -cd "[a-fA-F0-9.:/] ")
   if [ ${#GUID} -eq 64 ]; then