diff options
author | Christian Poessinger <christian@poessinger.com> | 2021-12-04 07:36:39 +0100 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2021-12-04 07:37:55 +0100 |
commit | 4683223c8ffcb10470f7a8a2eb48d57773ac73df (patch) | |
tree | 522d2228d68e597fb7fc3609b883fd97fef0b0fd /src/helpers/vyos-check-wwan.py | |
parent | 1edacb9c1788db06de570d25e274a7a7df8e81e8 (diff) | |
download | vyos-1x-4683223c8ffcb10470f7a8a2eb48d57773ac73df.tar.gz vyos-1x-4683223c8ffcb10470f7a8a2eb48d57773ac73df.zip |
wwan: T3795: move implementation to VbashOpRun()
After commit ae16a51506c ("configquery: T3402: use vyatta-op-cmd-wrapper to
provide environment") we can now call VyOS op-mode commands from arbitrary
Python scripts.
Diffstat (limited to 'src/helpers/vyos-check-wwan.py')
-rwxr-xr-x | src/helpers/vyos-check-wwan.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/helpers/vyos-check-wwan.py b/src/helpers/vyos-check-wwan.py index c6e6c54b7..2ff9a574f 100755 --- a/src/helpers/vyos-check-wwan.py +++ b/src/helpers/vyos-check-wwan.py @@ -18,7 +18,6 @@ from vyos.configquery import VbashOpRun from vyos.configquery import ConfigTreeQuery from vyos.util import is_wwan_connected -from vyos.util import call conf = ConfigTreeQuery() dict = conf.get_config_dict(['interfaces', 'wwan'], key_mangling=('-', '_'), @@ -30,8 +29,7 @@ for interface, interface_config in dict.items(): # do not restart this interface as it's disabled by the user continue - #op = VbashOpRun() - #op.run(['connect', 'interface', interface]) - call(f'VYOS_TAGNODE_VALUE={interface} /usr/libexec/vyos/conf_mode/interfaces-wwan.py') + op = VbashOpRun() + op.run(['connect', 'interface', interface]) exit(0) |