Fix ACL json translation (#794)
* Fix ACL json translation * Fix json translation tests
This commit is contained in:
parent
18627bcf36
commit
1248cc80e7
@ -1,6 +1,6 @@
|
||||
[
|
||||
{
|
||||
"ACL_TABLE:dataacl":{
|
||||
"ACL_TABLE:DATAACL":{
|
||||
"policy_desc":"dataacl",
|
||||
"ports":"Ethernet112,Ethernet116,Ethernet120,Ethernet124",
|
||||
"type":"L3"
|
||||
|
@ -1,6 +1,6 @@
|
||||
[
|
||||
{
|
||||
"ACL_TABLE:everflow":{
|
||||
"ACL_TABLE:EVERFLOW":{
|
||||
"policy_desc":"everflow",
|
||||
"ports":"Ethernet24,Ethernet40,Ethernet20,Ethernet44,Ethernet48,Ethernet28,Ethernet96,Ethernet92,Ethernet76,Ethernet116,Ethernet72,Ethernet112,Ethernet52,Ethernet108,Ethernet56,Ethernet32,Ethernet16,Ethernet36,Ethernet12,Ethernet120,Ethernet8,Ethernet4,Ethernet0,Ethernet124,Ethernet68,Ethernet84,Ethernet100,Ethernet80,Ethernet60,Ethernet104,Ethernet64,Ethernet88",
|
||||
"type":"mirror"
|
||||
|
@ -120,7 +120,7 @@ def generate_table_json(aclset, aclname, ports, mirror, max_priority, output_pat
|
||||
table_props["ports"] = ports
|
||||
|
||||
table_data = [{}]
|
||||
table_data[0]["ACL_TABLE:"+table_name] = table_props
|
||||
table_data[0]["ACL_TABLE:"+table_name.upper()] = table_props
|
||||
table_data[0]["OP"] = "SET"
|
||||
dump_json(os.path.join(output_path, "table_"+table_name+".json"), table_data)
|
||||
|
||||
|
Reference in New Issue
Block a user