2021-01-15 13:15:31 +00:00
|
|
|
package aws
|
|
|
|
|
2021-04-26 15:24:57 +00:00
|
|
|
import (
|
|
|
|
"github.com/cloudskiff/driftctl/pkg/resource"
|
|
|
|
)
|
2021-03-25 11:13:52 +00:00
|
|
|
|
2021-01-15 13:15:31 +00:00
|
|
|
const AwsDefaultSecurityGroupResourceType = "aws_default_security_group"
|
|
|
|
|
2021-04-26 15:24:57 +00:00
|
|
|
func initAwsDefaultSecurityGroupMetaData(resourceSchemaRepository resource.SchemaRepositoryInterface) {
|
2021-08-09 14:03:04 +00:00
|
|
|
resourceSchemaRepository.SetNormalizeFunc(AwsDefaultSecurityGroupResourceType, func(res *resource.Resource) {
|
2021-05-24 15:19:06 +00:00
|
|
|
val := res.Attrs
|
2021-04-26 15:24:57 +00:00
|
|
|
val.SafeDelete([]string{"revoke_rules_on_delete"})
|
|
|
|
val.SafeDelete([]string{"ingress"})
|
|
|
|
val.SafeDelete([]string{"egress"})
|
|
|
|
})
|
2021-09-17 15:16:06 +00:00
|
|
|
resourceSchemaRepository.SetFlags(AwsDefaultSecurityGroupResourceType, resource.FlagDeepMode)
|
2021-04-26 15:24:57 +00:00
|
|
|
}
|