Merge pull request #8558 from zhongwencool/note-include-conf-check-result

chore: conf check cli notes include conf result
This commit is contained in:
zhongwencool 2022-07-25 17:28:08 +08:00 committed by GitHub
commit b7bcb9ea11
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 1 deletions

View File

@ -836,7 +836,12 @@ case "$1" in
;;
check_conf)
generate_config "check_only"
echo "$RUNNER_ETC_DIR/emqx.conf is ok"
INCLUDE_CONFS=$(< "$RUNNER_ETC_DIR/emqx.conf" grep "include" |awk '{print $2}'|xargs)
if [ "$INCLUDE_CONFS" == "" ]; then
echo "$RUNNER_ETC_DIR/emqx.conf is ok"
else
echo "$RUNNER_ETC_DIR/emqx.conf(include $INCLUDE_CONFS) is ok"
fi
;;
ctl)