netbox-community / netbox

The premier source of truth powering network automation. Open source under Apache 2. Try NetBox Cloud free: https://netboxlabs.com/free-netbox-cloud/
http://netboxlabs.com/oss/netbox/
Apache License 2.0
16.17k stars 2.59k forks source link

IPAM - Custom "Roles" for IP addresses #11169

Closed aleheux-tc closed 1 year ago

aleheux-tc commented 1 year ago

NetBox version

v3.3.9

Feature type

Change to existing functionality

Proposed functionality

Make the list or roles completely configurable.

Every platform, every network, every situation has unique requirements and there is no one fixed list that could possibly 1. make sense and 2. be useful.

I would comment on https://github.com/netbox-community/netbox/issues/9000 but that's been locked.

Use case

This is not the first time this is requested:

https://github.com/netbox-community/netbox/issues/9000

That issue was closed with a comment of "I'm going to close this as the proposal conflicts with an intentional design choice". The design choice being to limit the roles to an arbitrary list because "they [the roles] are not arbitrary"

Let's examine the current list:

Loopback - This is a role that's attributed to interfaces, not IPs. Any IP assigned to a loopback interface is a loopback IP. No IP assigned to a different interface is ever a loopback IP. This is not even arbitrary, this doesn't even make any sense.

Secondary - Some platforms (Cisco) have the concept of Secondary IPs on interfaces. Other platforms (Juniper) have the opposite, some IPs on an interface can be marked as Primary. Other platforms (*nix) have neither. Why include Secondary but not Primary? Arbitrary.

Anycast - IPs are not "anycast". Anycast is a routing design pattern. This is even worse than "loopback"

VIP - Ok, IPs can be Virtual IPs and on some platforms this is a useful distinction to make, like in the case of VRRP. Although to properly define VRRP on an interface one needs a lot more than just a "VIP" tag on an IP address.

VRRP - Wait. Didn't we already have a VIP role? Now what?

This shows that the existing list is completely arbitrary. It's possible that the current list makes sense on some platform out there or in some specific network, but it's not at all generic or in any way a standard list of roles.

Allowing the list of role to be customized would make this field actually usable for its intended purpose.

Database changes

No response

External dependencies

No response

jeremystretch commented 1 year ago

This topic has already been beaten to death, and I'm not going to rehash the discussion every time someone takes issue with it. The available roles are clearly documented, and each serves a distinct purpose. If you're not happy with the available choices, you're free to fork NetBox and make whatever changed you'd like to meet your needs.