proxy_centos/bin/add_ip_to_squid_conf.sh

14 lines
255 B
Bash
Raw Normal View History

2022-02-11 19:41:01 -06:00
#!/usr/bin/env bash
# this script will add a new ip address to squid config.
IP="$1"
PORT="$2"
cat << EOF
http_port $IP:$PORT name=$PORT
acl tasty$PORT myportname $PORT src 0.0.0.0/0
http_access allow tasty$PORT
2022-02-11 19:57:23 -06:00
tcp_outgoing_address $IP tasty$PORT
2022-02-11 19:41:01 -06:00
EOF