Skip to content
Snippets Groups Projects
Verified Commit 68dc9b99 authored by Karel van Klink's avatar Karel van Klink :smiley_cat:
Browse files

Don't run edge port validation on Juniper routers

parent 9d951b3b
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !424. Comments created here will be created in the context of that merge request.
...@@ -78,21 +78,22 @@ def verify_base_config(subscription: dict[str, Any]) -> LSOState: ...@@ -78,21 +78,22 @@ def verify_base_config(subscription: dict[str, Any]) -> LSOState:
"Validate Edge Port Configuration", target=Target.SYSTEM, initial_input_form=wrap_modify_initial_input_form(None) "Validate Edge Port Configuration", target=Target.SYSTEM, initial_input_form=wrap_modify_initial_input_form(None)
) )
def validate_edge_port() -> StepList: def validate_edge_port() -> StepList:
"""Validate an existing, active Edge port subscription. """Validate an existing, active Edge port subscription if it is on a Nokia device.
* Check correct configuration of interfaces in NetBox, only when the Edge Port is on a Nokia device. * Check correct configuration of interfaces in NetBox.
* Verify create Edge port configuration. * Verify create Edge port configuration.
""" """
edge_port_is_on_nokia = conditional( edge_port_is_on_juniper = conditional(
lambda state: state["subscription"]["edge_port"]["node"]["vendor"] == Vendor.NOKIA lambda state: state["subscription"]["edge_port"]["node"]["vendor"] == Vendor.JUNIPER
) )
return ( return (
begin begin
>> store_process_subscription(Target.SYSTEM) >> store_process_subscription(Target.SYSTEM)
>> unsync
>> prepare_state >> prepare_state
>> edge_port_is_on_nokia(verify_netbox_entries) >> edge_port_is_on_juniper(done)
>> unsync
>> verify_netbox_entries
>> anonymous_lso_interaction(verify_base_config) >> anonymous_lso_interaction(verify_base_config)
>> resync >> resync
>> done >> done
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment