Skip to content
Snippets Groups Projects
Commit 7f913205 authored by Aleksandr Kurbatov's avatar Aleksandr Kurbatov
Browse files

validate_edge_port: add partner_name

parent 7420e8b3
No related branches found
No related tags found
1 merge request!294validate_edge_port: add partner_name
Pipeline #89887 passed
......@@ -12,6 +12,7 @@ from orchestrator.workflows.utils import wrap_modify_initial_input_form
from gso.products.product_types.edge_port import EdgePort
from gso.services.lso_client import LSOState, anonymous_lso_interaction
from gso.services.netbox_client import NetboxClient
from gso.services.partners import get_partner_by_id
@step("Prepare required keys in state")
......@@ -58,12 +59,14 @@ def verify_netbox_entries(subscription: EdgePort) -> None:
@step("Check base config for drift")
def verify_base_config(subscription: dict[str, Any]) -> LSOState:
"""Workflow step for running a playbook that checks whether base config has drifted."""
partner_name = get_partner_by_id(subscription["customer_id"]).name
return {
"playbook_name": "gap_ansible/playbooks/edge_port.yaml",
"inventory": {"all": {"hosts": {subscription["edge_port"]["node"]["router_fqdn"]: None}}},
"extra_vars": {
"dry_run": True,
"subscription": subscription,
"partner_name": partner_name,
"verb": "create",
"is_verification_workflow": "true",
},
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment