driftctl/pkg/resource/aws/aws_cloudfront_distribution.go

20 lines
708 B
Go
Raw Normal View History

2021-02-17 14:33:08 +00:00
package aws
2021-03-26 08:44:55 +00:00
import (
"github.com/cloudskiff/driftctl/pkg/resource"
)
2021-03-25 11:13:52 +00:00
2021-02-17 14:33:08 +00:00
const AwsCloudfrontDistributionResourceType = "aws_cloudfront_distribution"
2021-03-26 08:44:55 +00:00
func initAwsCloudfrontDistributionMetaData(resourceSchemaRepository resource.SchemaRepositoryInterface) {
2021-08-09 14:03:04 +00:00
resourceSchemaRepository.SetNormalizeFunc(AwsCloudfrontDistributionResourceType, func(res *resource.Resource) {
val := res.Attrs
2021-03-26 08:44:55 +00:00
val.SafeDelete([]string{"etag"})
val.SafeDelete([]string{"last_modified_time"})
val.SafeDelete([]string{"retain_on_delete"})
val.SafeDelete([]string{"status"})
val.SafeDelete([]string{"wait_for_deployment"})
})
2021-09-17 15:16:06 +00:00
resourceSchemaRepository.SetFlags(AwsCloudfrontDistributionResourceType, resource.FlagDeepMode)
2021-03-26 08:44:55 +00:00
}