diff options
author | Daniil Baturin <daniil@baturin.org> | 2019-08-14 13:25:10 -0400 |
---|---|---|
committer | Daniil Baturin <daniil@baturin.org> | 2019-08-14 13:25:10 -0400 |
commit | 589952faadcf7700702b24390c1d654706f3a857 (patch) | |
tree | b3d486d0b0bc9e08d706d16d852bcae60b504dc0 /src/completion/list_interfaces.py | |
parent | 4e781d4dec184308ac844a4c2ff7dcfc7832cc77 (diff) | |
parent | 8d1e768a6f3285ed717f588f356db9340871b043 (diff) | |
download | vyos-1x-589952faadcf7700702b24390c1d654706f3a857.tar.gz vyos-1x-589952faadcf7700702b24390c1d654706f3a857.zip |
Merge branch 'current' into equuleus
Diffstat (limited to 'src/completion/list_interfaces.py')
-rwxr-xr-x | src/completion/list_interfaces.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/completion/list_interfaces.py b/src/completion/list_interfaces.py index a4968c52f..66432af19 100755 --- a/src/completion/list_interfaces.py +++ b/src/completion/list_interfaces.py @@ -10,6 +10,7 @@ parser = argparse.ArgumentParser() group = parser.add_mutually_exclusive_group() group.add_argument("-t", "--type", type=str, help="List interfaces of specific type") group.add_argument("-b", "--broadcast", action="store_true", help="List all broadcast interfaces") +group.add_argument("-br", "--bridgeable", action="store_true", help="List all bridgeable interfaces") args = parser.parse_args() @@ -25,6 +26,14 @@ elif args.broadcast: bridge = vyos.interfaces.list_interfaces_of_type("bridge") bond = vyos.interfaces.list_interfaces_of_type("bonding") interfaces = eth + bridge + bond +elif args.bridgeable: + eth = vyos.interfaces.list_interfaces_of_type("ethernet") + bond = vyos.interfaces.list_interfaces_of_type("bonding") + l2tpv3 = vyos.interfaces.list_interfaces_of_type("l2tpv3") + openvpn = vyos.interfaces.list_interfaces_of_type("openvpn") + vxlan = vyos.interfaces.list_interfaces_of_type("vxlan") + wireless = vyos.interfaces.list_interfaces_of_type("wireless") + interfaces = eth + bond + l2tpv3 + openvpn + vxlan + wireless else: interfaces = vyos.interfaces.list_interfaces() |