mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-11 05:17:44 +03:00
test-network: support the case that l2tp module is not supported
Hopefully fixes the issue reported at https://github.com/systemd/systemd-centos-ci/pull/517#issuecomment-1205399798.
This commit is contained in:
parent
f17061ef95
commit
49ad287292
@ -475,8 +475,10 @@ def flush_fou_ports():
|
||||
|
||||
def flush_l2tp_tunnels():
|
||||
tids = []
|
||||
output = check_output('ip l2tp show tunnel')
|
||||
for line in output.splitlines():
|
||||
ret = run('ip l2tp show tunnel')
|
||||
if ret.returncode != 0:
|
||||
return # l2tp may not be supported
|
||||
for line in ret.stdout.splitlines():
|
||||
words = line.split()
|
||||
if words[0] == 'Tunnel':
|
||||
tid = words[1].rstrip(',')
|
||||
|
Loading…
Reference in New Issue
Block a user