clean up naming: s/SIPCON_REMOTE/PBX_SIP etc

Change-Id: Ie66b32466f80d930150ea940d236cfbbe026fc50
diff --git a/net/config_2g3g b/net/config_2g3g
index b3f0264..0cdd9a0 100644
--- a/net/config_2g3g
+++ b/net/config_2g3g
@@ -106,15 +106,17 @@
 GGSN_GTP_STATE_DIR=/tmp
 
 # Enabled only when MSC_MNCC != "internal"
-SIPCON_LOCAL="${TO_SIP_IP}"
-SIPCON_LOCAL_PORT="5060"
-SIPCON_REMOTE="127.0.0.1"
-SIPCON_REMOTE_PORT="5069"
-# SIPCON_SERVER:
+SIPCON_SIP="${TO_SIP_IP}"
+SIPCON_SIP_PORT="5060"
+
+# PBX_SERVER:
 #  "kamailio" -- launch kamailio
 #  "freeswitch" -- launch freeswitch
 #  "none" -- launch no server, use remotely running SIP server
-SIPCON_SERVER="kamailio"
+PBX_SERVER="kamailio"
+PBX_SIP="${TO_SIP_IP}"
+PBX_SIP_PORT=5069
+PBX_LO_IP=127.0.0.1
 
 LOG_OUTPUT0_TYPE=stderr
 LOG_OUTPUT1_TYPE=file current_log/${_name}.log
diff --git a/net/templates/kamailio.cfg b/net/templates/kamailio.cfg
index b0e2bf3..91df55f 100644
--- a/net/templates/kamailio.cfg
+++ b/net/templates/kamailio.cfg
@@ -47,11 +47,11 @@
 
 /* uncomment and configure the following line if you want Kamailio to
    bind on a specific interface/port/proto (default bind on all available) */
-listen=${SIPCON_REMOTE}:${SIPCON_REMOTE_PORT}
+listen=${PBX_SIP}:${PBX_SIP_PORT}
 
 /* port to listen to
  * - can be specified more than once if needed to listen on many ports */
-port=${SIPCON_REMOTE_PORT}
+port=${PBX_SIP_PORT}
 
 # life time of TCP connection when there is no traffic
 # - a bit higher than registration expires to cope with UA behind NAT
@@ -73,7 +73,7 @@
 # pstn.gw_ip = "10.0.0.101" desc "My PSTN GW Address"
 #
 # - by default is empty to avoid misrouting
-pstn.gw_ip = "${SIPCON_LOCAL}:${SIPCON_LOCAL_PORT}" desc "osmo-sip-connector Address"
+pstn.gw_ip = "${SIPCON_SIP}:${SIPCON_SIP_PORT}" desc "osmo-sip-connector Address"
 #!endif
 
 
diff --git a/net/templates/osmo-sip-connector.cfg b/net/templates/osmo-sip-connector.cfg
index 5f067ef..88aa5b7 100644
--- a/net/templates/osmo-sip-connector.cfg
+++ b/net/templates/osmo-sip-connector.cfg
@@ -3,8 +3,8 @@
 mncc
   socket-path ${MSC_MNCC_SOCKET}
 sip
-  local ${SIPCON_LOCAL} ${SIPCON_LOCAL_PORT}
-  remote ${SIPCON_REMOTE} ${SIPCON_REMOTE_PORT}
+  local ${SIPCON_SIP} ${SIPCON_SIP_PORT}
+  remote ${PBX_SIP} ${PBX_SIP_PORT}
 
 ${foreach(LOG_OUTPUT)}
 log ${LOG_OUTPUTn_TYPE}
diff --git a/net/templates/run.sh b/net/templates/run.sh
index e9b7bb2..0eacb0f 100755
--- a/net/templates/run.sh
+++ b/net/templates/run.sh
@@ -86,7 +86,7 @@
 if [ "x${MSC_MNCC}" != "xinternal" ]; then
   sipcon="osmo-sip-connector -c osmo-sip-connector.cfg"
 
-  case "${SIPCON_SERVER}" in
+  case "${PBX_SERVER}" in
     "kamailio")
       # Require kamailio (PATH hack is needed for Debian)
       kamailio="$(PATH="$PATH:/usr/sbin:/sbin" which kamailio)"
@@ -108,7 +108,7 @@
    "none")
       ;;
    *)
-     echo "ERROR: unknown value "${SIPCON_SERVER}" for SIPCON_SERVER!"
+     echo "ERROR: unknown value ${PBX_SERVER} for SIPCON_SERVER!"
      exit 1
      ;;
   esac
@@ -141,7 +141,7 @@
   sleep .2
   term "$sipcon" SIPCON &
   sleep .2
-  case "${SIPCON_SERVER}" in
+  case "${PBX_SERVER}" in
     "kamailio") term "$kamailio" KAMAILIO &;;
     "freeswitch") term "./freeswitch/freeswitch.sh" FREESWITCH &;;
   esac
@@ -171,7 +171,7 @@
 if [ "x${MSC_MNCC}" != "xinternal" ]; then
   # 'killall' seems to work only with the shortened name
   killall osmo-sip-connec
-  killall "${SIPCON_SERVER}"
+  killall "${PBX_SERVER}"
 fi