-
Notifications
You must be signed in to change notification settings - Fork 351
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
T7076: Add script to validate ethernet interface #4327
Conversation
👍 |
src/validators/ethernet-interface
Outdated
@@ -0,0 +1,13 @@ | |||
#!/bin/sh | |||
|
|||
if [[ "$1" != eth* ]]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
python/vyos/ifconfig/ethernet.py
lists the following ethernet interface name regex: (lan|eth|eno|ens|enp|enx)[0-9]+$
As some boards/flavors in the past used lan as interface name. We should thing if this is really what we want or streamline everything to eth
- which could mix up the labelling on the appliance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@zdc should I add this regex (lan|eth|eno|ens|enp|enx)[0-9]+$
to check all possible ethernet interfaces?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We do not allow other names for vpp
Initially, this validator was created to check this https://vyos.dev/T7076
I'm not against (lan|eth|eno|ens|enp|enx)[0-9]+$
if it can be reused for some other checks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed
CI integration 👍 passed! Details
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may use non-eth names in the future on some platforms and we have other scripts with that regex, so let's do that.
Change summary
Types of changes
Related Task(s)
Related PR(s)
vyos/vyos-vpp#6
How to test / Smoketest result
Checklist: