summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorThomas Mangin <thomas.mangin@exa.net.uk>2020-03-24 18:23:03 +0000
committerThomas Mangin <thomas.mangin@exa.net.uk>2020-03-24 18:23:03 +0000
commitd08df9402f6504582370a68666d8226350e53a19 (patch)
tree566f636e1bb998f676f3598e75e61ba90c0912d2 /src
parent8a4dd6c2816bf2289ad4af37ba301b31efdf30a8 (diff)
downloadvyos-1x-d08df9402f6504582370a68666d8226350e53a19.tar.gz
vyos-1x-d08df9402f6504582370a68666d8226350e53a19.zip
ifconfig: T2057: add VTunIf class
Diffstat (limited to 'src')
-rwxr-xr-xsrc/conf_mode/interfaces-openvpn.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/conf_mode/interfaces-openvpn.py b/src/conf_mode/interfaces-openvpn.py
index 3a3c69e37..d72e4111c 100755
--- a/src/conf_mode/interfaces-openvpn.py
+++ b/src/conf_mode/interfaces-openvpn.py
@@ -31,7 +31,7 @@ from time import sleep
from vyos import ConfigError
from vyos.config import Config
-from vyos.ifconfig import Interface
+from vyos.ifconfig import VTunIf
from vyos.validate import is_addr_assigned
user = 'openvpn'
@@ -1025,14 +1025,14 @@ def apply(openvpn):
try:
# we need to catch the exception if the interface is not up due to
# reason stated above
- Interface(openvpn['intf']).set_alias(openvpn['description'])
+ VTunIf(openvpn['intf']).set_alias(openvpn['description'])
except:
pass
# TAP interface needs to be brought up explicitly
if openvpn['type'] == 'tap':
if not openvpn['disable']:
- Interface(openvpn['intf']).set_state('up')
+ VTunIf(openvpn['intf']).set_state('up')
return None