opsmill / infrahub

Infrahub - A new approach to Infrastructure Management
https://opsmill.com/
GNU Affero General Public License v3.0
148 stars 7 forks source link

feature: be able to use related node HFID into node HFID/uniqueness_constraint #3680

Open BeArchiTek opened 2 weeks ago

BeArchiTek commented 2 weeks ago

Component

API Server / GraphQL, Python SDK

Describe the Feature Request

As a user, defining an HFID I would like to use the HFID of a related node instead of the other attributes

Describe the Use Case

Use case 1 An VLAN must be unique per Site, but my Site uniqueness is not is name only, but his name and his Owner shortname ( uniquness_constraint: [ namevalue, ownershortname__value ]

Use case 2 When syncing data from other tool Netbox for example) some constraints can’t be enforce with the current constraint as the uniqueness of a Model may need the uniqueness of another one like An interface must be unique per device, but my device uniqueness is not is name only, but his name on a location ( uniquness_constraint: [ namevalue, locationname__value ]

Additional Information

No response