Global Variable local ip v4

From FreeSWITCH Wiki
Jump to: navigation, search


This global variable is automatically set by FreeSWITCH. You may override this global variable in vars.xml


<!-- Set local_ip_v4 to hard-coded IP -->
<X-PRE-PROCESS cmd="set" data="local_ip_v4="/>

<!-- Set local_ip_v4 to eth1 address -->
<X-PRE-PROCESS cmd="exec-set" data="local_ip_v4=ip addr show eth1 | awk '/inet /{print $2}' | head -n 1 | cut -d '/' -f 1"/>

See also: