Skip to content

Commit be178cf

Browse files
Update AWS provider/module and generated content (#637)
Co-authored-by: wata727 <[email protected]>
1 parent 86c3c91 commit be178cf

14 files changed

+75
-21
lines changed

go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ go 1.22.2
44

55
require (
66
github.com/agext/levenshtein v1.2.2 // indirect
7-
github.com/aws/aws-sdk-go v1.52.1
7+
github.com/aws/aws-sdk-go v1.53.19
88
github.com/dave/dst v0.27.3
99
github.com/fatih/color v1.13.0 // indirect
1010
github.com/golang/mock v1.6.0

go.sum

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ github.com/agext/levenshtein v1.2.2/go.mod h1:JEDfjyjHDjOF/1e4FlBE/PkbqA9OfWu2ki
33
github.com/apparentlymart/go-textseg/v15 v15.0.0 h1:uYvfpb3DyLSCGWnctWKGj857c6ew1u1fNQOlOtuGxQY=
44
github.com/apparentlymart/go-textseg/v15 v15.0.0/go.mod h1:K8XmNZdhEBkdlyDdvbmmsvpAG721bKi0joRfFdHIWJ4=
55
github.com/aws/aws-sdk-go v1.31.9/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0=
6-
github.com/aws/aws-sdk-go v1.52.1 h1:pYpPIuvVsawYDR0Nt3VrceizUAbtpTN3Z7xBzcZWwfI=
7-
github.com/aws/aws-sdk-go v1.52.1/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk=
6+
github.com/aws/aws-sdk-go v1.53.19 h1:WEuWc918RXlIaPCyU11F7hH9H1ItK+8m2c/uoQNRUok=
7+
github.com/aws/aws-sdk-go v1.53.19/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk=
88
github.com/bufbuild/protocompile v0.4.0 h1:LbFKd2XowZvQ/kajzguUp2DC9UEIQhIq77fZZlaQsNA=
99
github.com/bufbuild/protocompile v0.4.0/go.mod h1:3v93+mbWn/v3xzN+31nwkJfrEpAUwp+BagBSZWx+TP8=
1010
github.com/dave/dst v0.27.3 h1:P1HPoMza3cMEquVf9kKy8yXsFirry4zEnWOdYPOoIzY=

rules/models/aws-sdk-go

Submodule aws-sdk-go updated 326 files

rules/models/aws_alb_invalid_ip_address_type.go

+1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ func NewAwsALBInvalidIPAddressTypeRule() *AwsALBInvalidIPAddressTypeRule {
2727
enum: []string{
2828
"ipv4",
2929
"dualstack",
30+
"dualstack-without-public-ipv4",
3031
},
3132
}
3233
}

rules/models/aws_glue_connection_invalid_connection_type.go

+1
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ func NewAwsGlueConnectionInvalidConnectionTypeRule() *AwsGlueConnectionInvalidCo
3232
"NETWORK",
3333
"MARKETPLACE",
3434
"CUSTOM",
35+
"SALESFORCE",
3536
},
3637
}
3738
}

rules/models/aws_instance_invalid_type.go

+9
Original file line numberDiff line numberDiff line change
@@ -821,6 +821,15 @@ func NewAwsInstanceInvalidTypeRule() *AwsInstanceInvalidTypeRule {
821821
"g6.48xlarge",
822822
"gr6.4xlarge",
823823
"gr6.8xlarge",
824+
"c7i-flex.large",
825+
"c7i-flex.xlarge",
826+
"c7i-flex.2xlarge",
827+
"c7i-flex.4xlarge",
828+
"c7i-flex.8xlarge",
829+
"u7i-12tb.224xlarge",
830+
"u7in-16tb.224xlarge",
831+
"u7in-24tb.224xlarge",
832+
"u7in-32tb.224xlarge",
824833
},
825834
}
826835
}

rules/models/aws_launch_configuration_invalid_type.go

+9
Original file line numberDiff line numberDiff line change
@@ -821,6 +821,15 @@ func NewAwsLaunchConfigurationInvalidTypeRule() *AwsLaunchConfigurationInvalidTy
821821
"g6.48xlarge",
822822
"gr6.4xlarge",
823823
"gr6.8xlarge",
824+
"c7i-flex.large",
825+
"c7i-flex.xlarge",
826+
"c7i-flex.2xlarge",
827+
"c7i-flex.4xlarge",
828+
"c7i-flex.8xlarge",
829+
"u7i-12tb.224xlarge",
830+
"u7in-16tb.224xlarge",
831+
"u7in-24tb.224xlarge",
832+
"u7in-32tb.224xlarge",
824833
},
825834
}
826835
}

rules/models/aws_launch_template_invalid_instance_type.go

+9
Original file line numberDiff line numberDiff line change
@@ -821,6 +821,15 @@ func NewAwsLaunchTemplateInvalidInstanceTypeRule() *AwsLaunchTemplateInvalidInst
821821
"g6.48xlarge",
822822
"gr6.4xlarge",
823823
"gr6.8xlarge",
824+
"c7i-flex.large",
825+
"c7i-flex.xlarge",
826+
"c7i-flex.2xlarge",
827+
"c7i-flex.4xlarge",
828+
"c7i-flex.8xlarge",
829+
"u7i-12tb.224xlarge",
830+
"u7in-16tb.224xlarge",
831+
"u7in-24tb.224xlarge",
832+
"u7in-32tb.224xlarge",
824833
},
825834
}
826835
}

rules/models/aws_lb_invalid_ip_address_type.go

+1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ func NewAwsLbInvalidIPAddressTypeRule() *AwsLbInvalidIPAddressTypeRule {
2727
enum: []string{
2828
"ipv4",
2929
"dualstack",
30+
"dualstack-without-public-ipv4",
3031
},
3132
}
3233
}

rules/models/aws_sagemaker_notebook_instance_invalid_instance_type.go

+8
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,14 @@ func NewAwsSagemakerNotebookInstanceInvalidInstanceTypeRule() *AwsSagemakerNoteb
182182
"ml.r6id.16xlarge",
183183
"ml.r6id.24xlarge",
184184
"ml.r6id.32xlarge",
185+
"ml.g6.xlarge",
186+
"ml.g6.2xlarge",
187+
"ml.g6.4xlarge",
188+
"ml.g6.8xlarge",
189+
"ml.g6.12xlarge",
190+
"ml.g6.16xlarge",
191+
"ml.g6.24xlarge",
192+
"ml.g6.48xlarge",
185193
},
186194
}
187195
}

rules/models/aws_transfer_ssh_key_invalid_body.go

+12
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
package models
44

55
import (
6+
"fmt"
7+
"regexp"
8+
69
"github.com/terraform-linters/tflint-plugin-sdk/hclext"
710
"github.com/terraform-linters/tflint-plugin-sdk/logger"
811
"github.com/terraform-linters/tflint-plugin-sdk/tflint"
@@ -15,6 +18,7 @@ type AwsTransferSSHKeyInvalidBodyRule struct {
1518
resourceType string
1619
attributeName string
1720
max int
21+
pattern *regexp.Regexp
1822
}
1923

2024
// NewAwsTransferSSHKeyInvalidBodyRule returns new rule with default attributes
@@ -23,6 +27,7 @@ func NewAwsTransferSSHKeyInvalidBodyRule() *AwsTransferSSHKeyInvalidBodyRule {
2327
resourceType: "aws_transfer_ssh_key",
2428
attributeName: "body",
2529
max: 2048,
30+
pattern: regexp.MustCompile(`^\s*(ssh|ecdsa)-[a-z0-9-]+[ \t]+(([A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{1,3})?(={0,3})?)(\s*|[ \t]+[\S \t]*\s*)$`),
2631
}
2732
}
2833

@@ -73,6 +78,13 @@ func (r *AwsTransferSSHKeyInvalidBodyRule) Check(runner tflint.Runner) error {
7378
attribute.Expr.Range(),
7479
)
7580
}
81+
if !r.pattern.MatchString(val) {
82+
runner.EmitIssue(
83+
r,
84+
fmt.Sprintf(`"%s" does not match valid pattern %s`, truncateLongMessage(val), `^\s*(ssh|ecdsa)-[a-z0-9-]+[ \t]+(([A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{1,3})?(={0,3})?)(\s*|[ \t]+[\S \t]*\s*)$`),
85+
attribute.Expr.Range(),
86+
)
87+
}
7688
return nil
7789
}, nil)
7890
if err != nil {

rules/tags/resources.go

+4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tools/provider-schema/.terraform.lock.hcl

+16-16
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tools/provider-schema/schema.json

+1-1
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)