mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-19 21:04:06 -07:00
Subroutine for mod_remoteip in /bin/v-add-sys-ip
This commit is contained in:
parent
654838bfc8
commit
579b1acd80
1 changed files with 6 additions and 0 deletions
|
@ -142,6 +142,12 @@ if [ ! -z "$PROXY_SYSTEM" ]; then
|
||||||
rpaf_str="$rpaf_str $ip"
|
rpaf_str="$rpaf_str $ip"
|
||||||
sed -i "s/.*RPAFproxy_ips.*/$rpaf_str/" $rpaf_conf
|
sed -i "s/.*RPAFproxy_ips.*/$rpaf_str/" $rpaf_conf
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#mod_remoteip
|
||||||
|
remoteip_conf="/etc/$WEB_SYSTEM/mods-enabled/remoteip.conf"
|
||||||
|
if [ $( grep -ic "$ip" $remoteip_conf ) -eq 0 ]; then
|
||||||
|
sed -i "s/<\/IfModule>/RemoteIPInternalProxy $ip\n<\/IfModule>/g" $remoteip_conf
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue