driftctl/pkg/resource/aws/aws_security_group.go

19 lines
622 B
Go
Raw Normal View History

package aws
import (
"github.com/snyk/driftctl/enumeration/resource"
"github.com/snyk/driftctl/enumeration/resource/aws"
)
2021-05-10 16:02:57 +00:00
func initAwsSecurityGroupMetaData(resourceSchemaRepository resource.SchemaRepositoryInterface) {
resourceSchemaRepository.SetNormalizeFunc(aws.AwsSecurityGroupResourceType, func(res *resource.Resource) {
val := res.Attrs
2021-05-10 16:02:57 +00:00
val.SafeDelete([]string{"revoke_rules_on_delete"})
val.SafeDelete([]string{"timeouts"})
// TODO We need to find a way to warn users that some rules in their states could be unmanaged
2021-05-10 16:02:57 +00:00
val.SafeDelete([]string{"ingress"})
val.SafeDelete([]string{"egress"})
})
}