sonic-utilities
sonic-utilities copied to clipboard
Add new cli to add a interface ip as secondary address
What I did
Added a new CLI command to add secondary subnet value.
How I did it
In the config class, added a snippet of code where the code to validate the secondary field and set the appropriate flag.
How to verify it
Added a test to validate the added flag
Previous command output (if the output of a command-line utility has changed)
New command output (if the output of a command-line utility has changed)
@venkatmahalingam can you review the PR?
@shbalaku-microsoft please make sure the new CLI is updated to https://github.com/sonic-net/sonic-utilities/blob/master/doc/Command-Reference.md
@venkatmahalingam , can you signoff?
@shbalaku-microsoft The design of the secondary IP seems to have an issue that hasn't been considered?
- If a VLAN interface has only an IPv6 address, it is also considered as the primary IP, and an IPv4 secondary IP can still be successfully configured.
- Deleting the primary IP seems to not check if the secondary IP exists?
@qiluo-msft can we merge this PR? Thanks.
Please merge latest master branch. The semgrep checker is added after this PR raised, so it will always block.
@shbalaku-microsoft , can you please rebase the code?
@shbalaku-microsoft kind reminder to rebase the code, so that we can merge this feature before 202405 fork date on 5/30