Remove np spec from kuryrnetworkpolicy annotations

Move the network policy spec from the kuryrnetworkpolicy annotations
to the spec.

Closes-Bug: 1802841
Change-Id: Ib2929c8a5ed28b44baf28f1d34353cc87c308451
This commit is contained in:
Luis Tomas Bolivar 2018-11-08 18:22:37 +01:00
parent e215a0ba4f
commit 0b211cda93
1 changed files with 2 additions and 2 deletions

View File

@ -167,14 +167,14 @@ class NetworkPolicyDriver(base.NetworkPolicyDriver):
'networkpolicy_name': networkpolicy_name,
'networkpolicy_namespace': namespace,
'networkpolicy_uid': policy['metadata']['uid'],
'networkpolicy_spec': policy['spec']
},
},
'spec': {
'securityGroupName': "sg-" + networkpolicy_name,
'securityGroupId': sg_id,
'ingressSgRules': i_rules,
'egressSgRules': e_rules
'egressSgRules': e_rules,
'networkpolicy_spec': policy['spec']
},
}
try: