mirror of
https://github.com/docker-mailserver/docker-mailserver.git
synced 2025-08-15 23:38:30 +02:00
scripts: apply fixes to helpers when using set -eE
(#3285)
For an upcoming PR, these changes are required, because the script that is using the helpers uses `set -eE`. This leads to situations where errors are not properly handled in our helpers (yet; I plan on changing that in the future).
This commit is contained in:
parent
449d53fc3f
commit
7e7497ae5a
4 changed files with 36 additions and 4 deletions
|
@ -123,9 +123,9 @@ function _get_log_level_or_default
|
|||
if [[ -n ${LOG_LEVEL+set} ]]
|
||||
then
|
||||
echo "${LOG_LEVEL}"
|
||||
elif [[ -e /etc/dms-settings ]]
|
||||
elif [[ -e /etc/dms-settings ]] && grep -q -E "^LOG_LEVEL='[a-z]+'" /etc/dms-settings
|
||||
then
|
||||
grep "^LOG_LEVEL=" /etc/dms-settings | cut -d "'" -f 2
|
||||
grep '^LOG_LEVEL=' /etc/dms-settings | cut -d "'" -f 2
|
||||
else
|
||||
echo 'info'
|
||||
fi
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue