summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobert "ar" Gerus <ar@bash.org.pl>2013-03-23 07:10:14 +0100
committerRobert "ar" Gerus <ar@bash.org.pl>2013-03-23 07:10:14 +0100
commit0087ca63d39b4fefe7f8295b057b4857db6c75da (patch)
tree55de6e2705f4964d7f2aafbcb8a52d3c94ad14c8
parente833daec81acc0d07d80a72b9314e39531b7084a (diff)
downloadold-firewall-0087ca63d39b4fefe7f8295b057b4857db6c75da.tar.gz
old-firewall-0087ca63d39b4fefe7f8295b057b4857db6c75da.tar.bz2
old-firewall-0087ca63d39b4fefe7f8295b057b4857db6c75da.zip
We may be able to use a second wan IP after all
-rw-r--r--fw.globals7
1 files changed, 7 insertions, 0 deletions
diff --git a/fw.globals b/fw.globals
index 7c8f093..8e384b5 100644
--- a/fw.globals
+++ b/fw.globals
@@ -17,6 +17,13 @@ HOST_AMANOJAKU="10.24.20.250"
#ROUTER
HOST_KASHA="10.24.0.1"
HOST_KASHA_WAN="192.168.0.11"
+HOST_KASHA_WAN2="$(/sbin/ip -4 a s dev eth0 | awk '$1 == "inet" && $2 != "192.168.0.11/24" { print $2; exit }')
+# will allow us to do things like: if ${HAVE_WAN2}; then ...
+if [[ -z "${HOST_KASHA_WAN2}" ]]; then
+ HAVE_WAN2="/bin/true"
+else
+ HAVE_WAN2="/bin/false"
+fi
#AP
HOST_HYPERION="10.24.0.254"