mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
CLOUDSTACK-7308: add tags to all security group rules
(cherry picked from commit ae1b87ca23997bcba75bfc7f59e83026e31a68fc)
This commit is contained in:
parent
de424061b2
commit
b035a444c6
@ -172,6 +172,16 @@ public class SecurityGroupJoinDaoImpl extends GenericDaoBase<SecurityGroupJoinVO
|
||||
ruleData.setCidr(vsg.getRuleAllowedSourceIpCidr());
|
||||
}
|
||||
|
||||
// add the tags to the rule data
|
||||
List<ResourceTagJoinVO> tags = _resourceTagJoinDao.listBy(vsg.getRuleUuid(), ResourceTag.ResourceObjectType.SecurityGroupRule);
|
||||
Set<ResourceTagResponse> tagResponse = new HashSet<ResourceTagResponse>();
|
||||
for (ResourceTagJoinVO tag: tags) {
|
||||
tagResponse.add(ApiDBUtils.newResourceTagResponse(tag, false));
|
||||
}
|
||||
|
||||
// add the tags to the rule data
|
||||
ruleData.setTags(tagResponse);
|
||||
|
||||
if (vsg.getRuleType() == SecurityRuleType.IngressRule) {
|
||||
ruleData.setObjectName("ingressrule");
|
||||
vsgData.addSecurityGroupIngressRule(ruleData);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user