With the following test configuration the error can be reproduced:
set interfaces openvpn vtun1 description 'fooo bar' set interfaces openvpn vtun1 local-address 10.255.1.2 set interfaces openvpn vtun1 local-host '172.18.201.10' set interfaces openvpn vtun1 local-port '1195' set interfaces openvpn vtun1 mode 'site-to-site' set interfaces openvpn vtun1 persistent-tunnel set interfaces openvpn vtun1 protocol 'udp' set interfaces openvpn vtun1 remote-address '10.255.1.1' set interfaces openvpn vtun1 remote-host '172.18.202.10' set interfaces openvpn vtun1 remote-port '1195' set interfaces openvpn vtun1 shared-secret-key-file '/config/auth/openvpn-1.key'
Traceback (most recent call last): File "/usr/libexec/vyos/conf_mode/interfaces-openvpn.py", line 886, in <module> c = get_config() File "/usr/libexec/vyos/conf_mode/interfaces-openvpn.py", line 482, in get_config default_server = getDefaultServer(server_network, openvpn['server_topology'], openvpn['type']) UnboundLocalError: local variable 'server_network' referenced before assignment