mirror of
https://github.com/myvesta/vesta
synced 2025-08-19 04:50:47 -07:00
Fix for better vhost matching
This commit is contained in:
parent
9087a5b57a
commit
ef9f28ecee
1 changed files with 2 additions and 2 deletions
|
@ -254,7 +254,7 @@ add_web_config() {
|
||||||
|
|
||||||
# Get config top and bottom line numbers
|
# Get config top and bottom line numbers
|
||||||
get_web_config_brds() {
|
get_web_config_brds() {
|
||||||
serv_line=$(grep -ni 'Name %domain_idn%' "$tpl_file" |cut -f 1 -d :)
|
serv_line=$(egrep -ni "Name %domain_idn%($| )" $tpl_file |cut -f 1 -d :)
|
||||||
if [ -z "$serv_line" ]; then
|
if [ -z "$serv_line" ]; then
|
||||||
log_event "$E_PARSING" "$EVENT"
|
log_event "$E_PARSING" "$EVENT"
|
||||||
return $E_PARSING
|
return $E_PARSING
|
||||||
|
@ -264,7 +264,7 @@ get_web_config_brds() {
|
||||||
bfr_line=$((serv_line - 1))
|
bfr_line=$((serv_line - 1))
|
||||||
aftr_line=$((last_line - serv_line - 1))
|
aftr_line=$((last_line - serv_line - 1))
|
||||||
|
|
||||||
str=$(grep -ni "Name $domain_idn" $conf | cut -f 1 -d :)
|
str=$(egrep -ni "Name $domain_idn($| )" $conf | cut -f 1 -d :)
|
||||||
top_line=$((str - serv_line + 1))
|
top_line=$((str - serv_line + 1))
|
||||||
bottom_line=$((top_line + last_line -1))
|
bottom_line=$((top_line + last_line -1))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue