Support nginx includes ending in wildcard *

This fixes cases like `include sites-enabled/*;` which is, e.g., the default config in Ubuntu.
This commit is contained in:
Phil Krylov 2021-10-08 18:33:26 +02:00 committed by GitHub
parent f5ee618986
commit 3f759069b1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3147,7 +3147,7 @@ _checkConf() {
_d="$1" _d="$1"
_c_file="$2" _c_file="$2"
_debug "Start _checkConf from:$_c_file" _debug "Start _checkConf from:$_c_file"
if [ ! -f "$2" ] && ! echo "$2" | grep '*$' >/dev/null && echo "$2" | grep '*' >/dev/null; then if [ ! -f "$2" ] && echo "$2" | grep '*' >/dev/null; then
_debug "wildcard" _debug "wildcard"
for _w_f in $2; do for _w_f in $2; do
if [ -f "$_w_f" ] && _checkConf "$1" "$_w_f"; then if [ -f "$_w_f" ] && _checkConf "$1" "$_w_f"; then