Skip to content

Commit

Permalink
dirty bash trick to filter out ip command output in order to avoid fa…
Browse files Browse the repository at this point in the history
…lse positive
  • Loading branch information
Jean M committed Nov 1, 2018
1 parent 1947486 commit e0aadfe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion configsnap
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,7 @@ if os.path.exists('/usr/bin/systemctl'):

report_info(
"Getting network details, firewall rules and listening services...")
run.run_command(['ip', 'address', 'show'],
run.run_command(['bash', '-c', 'ip a s | sed "/^\s\+valid_lft.*/d"'],
'ip_addresses', fail_ok=False, sort=False)
run.run_command(['ip', 'route', 'show'],
'ip_routes', fail_ok=False, sort=False)
Expand Down

0 comments on commit e0aadfe

Please sign in to comment.