Skip to content
Snippets Groups Projects
Commit 0f3f5ab7 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Update Tools.py

parent e57862b5
No related branches found
No related tags found
2 merge requests!142Release TeraFlowSDN 2.1,!139Fixes on OpenConfig and ACLs
......@@ -288,7 +288,7 @@ def compute_rules_to_add_delete(
acl_ruleset_name = config_rule.acl.rule_set.name # get the acl name
ACL_KEY_TEMPLATE = '/device[{:s}]/endpoint[{:s}]/acl_ruleset[{:s}]'
key_or_path = ACL_KEY_TEMPLATE.format(device_uuid, endpoint_uuid, acl_ruleset_name)
context_config_rules[key_or_path] = config_rule.acl # get the resource value of the acl
context_config_rules[key_or_path] = grpc_message_to_json(config_rule.acl) # get the resource value of the acl
request_config_rules = []
for config_rule in request.device_config.config_rules:
......@@ -304,7 +304,7 @@ def compute_rules_to_add_delete(
ACL_KEY_TEMPLATE = '/device[{:s}]/endpoint[{:s}]/acl_ruleset[{:s}]'
key_or_path = ACL_KEY_TEMPLATE.format(device_uuid, endpoint_uuid, acl_ruleset_name)
request_config_rules.append((
config_rule.action, key_or_path, config_rule.acl
config_rule.action, key_or_path, grpc_message_to_json(config_rule.acl)
))
resources_to_set : List[Tuple[str, Any]] = [] # key, value
......
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