Skip to content

Commit

Permalink
[ignore] Moved QOS_LEVEL to the constants.py
Browse files Browse the repository at this point in the history
  • Loading branch information
sajagana authored and lhercot committed Jan 22, 2025
1 parent 3158754 commit 29f7573
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
2 changes: 2 additions & 0 deletions plugins/module_utils/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,3 +211,5 @@

ORIGINATE_DEFAULT_ROUTE = {"only": "only", "in_addition": "inAddition", "": ""}
L3OUT_ROUTING_PROTOCOLS = {"bgp": ["bgp"], "ospf": ["ospf"], "bgpOspf": ["bgp", "ospf"], None: [None], "": None, "bgpospf": "bgpOspf", "ospfbgp": "bgpOspf"}

QOS_LEVEL = ["unspecified", "level1", "level2", "level3", "level4", "level5", "level6"]
4 changes: 3 additions & 1 deletion plugins/modules/mso_schema_template_anp_epg.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@
- Quality of Service (QoS) allows you to classify the network traffic in the fabric.
- It helps prioritize and police the traffic flow to help avoid congestion in the network.
- The Contract QoS Level parameter is supported on versions of MSO that are 3.1 or greater.
choices: [ unspecified, level1, level2, level3, level4, level5, level6 ]
type: str
epg_type:
description:
Expand Down Expand Up @@ -278,6 +279,7 @@

from ansible.module_utils.basic import AnsibleModule
from ansible_collections.cisco.mso.plugins.module_utils.mso import MSOModule, mso_argument_spec, mso_reference_spec, mso_epg_subnet_spec
from ansible_collections.cisco.mso.plugins.module_utils.constants import QOS_LEVEL


def main():
Expand All @@ -296,7 +298,7 @@ def main():
intersite_multicast_source=dict(type="bool"),
proxy_arp=dict(type="bool"),
subnets=dict(type="list", elements="dict", options=mso_epg_subnet_spec()),
qos_level=dict(type="str"),
qos_level=dict(type="str", choices=QOS_LEVEL),
epg_type=dict(type="str", choices=["application", "service"]),
deployment_type=dict(type="str", choices=["cloud_native", "cloud_native_managed", "third_party"]),
service_type=dict(type="str"),
Expand Down
4 changes: 2 additions & 2 deletions plugins/modules/mso_schema_template_contract_filter.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@

from ansible.module_utils.basic import AnsibleModule
from ansible_collections.cisco.mso.plugins.module_utils.mso import MSOModule, mso_argument_spec
from ansible_collections.cisco.mso.plugins.module_utils.constants import FILTER_KEY_MAP, PRIORITY_MAP
from ansible_collections.cisco.mso.plugins.module_utils.constants import FILTER_KEY_MAP, PRIORITY_MAP, QOS_LEVEL


def main():
Expand All @@ -188,7 +188,7 @@ def main():
filter_template=dict(type="str"),
filter_schema=dict(type="str"),
filter_type=dict(type="str", default="both-way", choices=list(FILTER_KEY_MAP), aliases=["type"]),
qos_level=dict(type="str", choices=["unspecified", "level1", "level2", "level3", "level4", "level5", "level6"]),
qos_level=dict(type="str", choices=QOS_LEVEL),
action=dict(type="str", choices=["permit", "deny"]),
priority=dict(type="str", choices=["default", "lowest_priority", "medium_priority", "highest_priority"]),
state=dict(type="str", default="present", choices=["absent", "present", "query"]),
Expand Down
3 changes: 2 additions & 1 deletion plugins/modules/mso_schema_template_external_epg.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@

from ansible.module_utils.basic import AnsibleModule
from ansible_collections.cisco.mso.plugins.module_utils.mso import MSOModule, mso_argument_spec, mso_reference_spec
from ansible_collections.cisco.mso.plugins.module_utils.constants import QOS_LEVEL


def main():
Expand All @@ -216,7 +217,7 @@ def main():
anp=dict(type="dict", options=mso_reference_spec()),
preferred_group=dict(type="bool"),
type=dict(type="str", default="on-premise", choices=["on-premise", "cloud"]),
qos_level=dict(type="str", choices=["unspecified", "level1", "level2", "level3", "level4", "level5", "level6"]),
qos_level=dict(type="str", choices=QOS_LEVEL),
state=dict(type="str", default="present", choices=["absent", "present", "query"]),
)

Expand Down

0 comments on commit 29f7573

Please sign in to comment.