The proper way to do it is probably to get the information from the command-line rather than the environment. The local ip address is the 4th parameter in the nm-openvpn-service-openvpn-helper call.
<cmd> tun_dev tun_mtu link_mtu ifconfig_local_ip ifconfig_remote_ip [ init | restart ]
Hm. Except that apparently it needs that information :
nm-openvpn[5945]: [server] Inactivity timeout (--ping-restart), restarting soft,ping- restart] received, process restarting network- manager- openvpn/ nm-openvpn- service- openvpn- helper tun0 1500 1541 10.8.0.6 10.8.0.5 restart connection_ ip4_config_ get: invalid IP4 config received! 4859]: segfault at 8 ip 000000000043fb1c sp 00007fff68955c80 error 4 in NetworkManager[ 400000+ 65000]
nm-openvpn[5945]: SIGUSR1[
[...]
nm-openvpn[5945]: /usr/lib/
NetworkManager: <info> VPN connection 'VPN connection 1' (IP Config Get) reply received.
NetworkManager: nm_vpn_
kernel: [ 480.167409] NetworkManager[
The proper way to do it is probably to get the information from the command-line rather than the environment. The local ip address is the 4th parameter in the nm-openvpn- service- openvpn- helper call.
<cmd> tun_dev tun_mtu link_mtu ifconfig_local_ip ifconfig_remote_ip [ init | restart ]