diff options
author | Daniil Baturin <daniil@vyos.io> | 2021-09-05 04:43:29 -0500 |
---|---|---|
committer | Daniil Baturin <daniil@vyos.io> | 2021-09-05 05:24:11 -0500 |
commit | e211cdbb375dba13af33d6ad6c3addab707f2870 (patch) | |
tree | 40012142de3ab378b89bbe58eae0fa3f1edb8ee9 /src | |
parent | 5e1f76d16332a917bfd99c6f2bffcd73e61d934d (diff) | |
download | vyos-1x-e211cdbb375dba13af33d6ad6c3addab707f2870.tar.gz vyos-1x-e211cdbb375dba13af33d6ad6c3addab707f2870.zip |
T3803: add source-address option to the op mode ping CLI.
Diffstat (limited to 'src')
-rwxr-xr-x | src/op_mode/ping.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/op_mode/ping.py b/src/op_mode/ping.py index 2144ab53c..60bbc0c78 100755 --- a/src/op_mode/ping.py +++ b/src/op_mode/ping.py @@ -62,8 +62,8 @@ options = { }, 'interface': { 'ping': '{command} -I {value}', - 'type': '<interface> <X.X.X.X> <h:h:h:h:h:h:h:h>', - 'help': 'Interface to use as source for ping' + 'type': '<interface>', + 'help': 'Source interface' }, 'interval': { 'ping': '{command} -i {value}', @@ -115,6 +115,10 @@ options = { 'type': '<bytes>', 'help': 'Number of bytes to send' }, + 'source-address': { + 'ping': '{command} -I {value}', + 'type': '<x.x.x.x> <h:h:h:h:h:h:h:h>', + }, 'ttl': { 'ping': '{command} -t {value}', 'type': '<ttl>', @@ -234,4 +238,4 @@ if __name__ == '__main__': # print(f'{command} {host}') os.system(f'{command} {host}') -
\ No newline at end of file + |