-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Introduce a separate model for virtual machine interfaces #4721
Comments
A VM could have physical interface or devices if it been done through PCI passthrough which makes physical PCI devices not directly seen or used in base hypervisor os but directly in a virtual machine as physical attached and when using scripts or automated discovery inside OS will see those interfaces showed as the physical interface but updates on netbox service might failed if they don't allow physical types of interfaces. Additionally, if Virtual Machine virtual interfaces can be connected to physical hypervisor device interfaces. In a general production environment, virtual machine interfaces usually tied to the specific physical interfaces of hypervisor so that hypervisor network traffic remains separate from virtual machine network traffic. For a user to know which virtual to the physical path has been taken could help when someone doing troubleshooting and wanted to end-to-end network connection path. |
@a31amit what you're describing is outside the scope of this issue. This proposal does not change any of the existing interface types or validation; it is merely for internal purposes. |
@jeremystretch thanks for the confirmation |
Locking as this issue is for some reason generating a lot of off-topic comments. |
Implemented by PR #4781 |
Proposed Changes
Justification
There are some fields on the current Interface model which don't really apply to virtual machine interfaces, namely
mgmt_only
andcable
. #4615 would introduce a physicallabel
field, which likewise does not apply. Similarly, VM interfaces are restricted to only virtual types. Using a separate model would mitigate the need for special validation when handling VM interfaces. It also greatly simplifies the definition and use of forms, serializers, etc.There are some downsides to the proposed change that should be pointed out:
The text was updated successfully, but these errors were encountered: