Skip to content

Commit

Permalink
Remove ARN Parameter from Firehose Resource
Browse files Browse the repository at this point in the history
Signed-off-by: Blake R <[email protected]>
  • Loading branch information
blakeromano committed Mar 22, 2024
1 parent cacdcfc commit affd2a0
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 37 deletions.
11 changes: 2 additions & 9 deletions apis/firehose/v1beta1/zz_deliverystream_types.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 0 additions & 10 deletions apis/firehose/v1beta1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions apis/firehose/v1beta1/zz_generated.resolvers.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 12 additions & 10 deletions config/firehose/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,28 +17,30 @@ func Configure(p *config.Provider) {
r.TerraformResource.Schema["splunk_configuration"].Elem.(*schema.Resource).Schema["hec_token"].Sensitive = true

r.References["extended_s3_configuration.role_arn"] = config.Reference{
Type: "github.com/upbound/provider-aws/apis/iam/v1beta1.Role",
Extractor: common.PathARNExtractor,
TerraformName: "aws_iam_role",
Extractor: common.PathARNExtractor,
}
r.References["extended_s3_configuration.bucket_arn"] = config.Reference{
Type: "github.com/upbound/provider-aws/apis/s3/v1beta1.Bucket",
Extractor: common.PathARNExtractor,
TerraformName: "aws_s3_bucket",
Extractor: common.PathARNExtractor,
}

r.References["s3_configuration.role_arn"] = config.Reference{
Type: "github.com/upbound/provider-aws/apis/iam/v1beta1.Role",
Extractor: common.PathARNExtractor,
TerraformName: "aws_iam_role",
Extractor: common.PathARNExtractor,
}
r.References["s3_configuration.bucket_arn"] = config.Reference{
Type: "github.com/upbound/provider-aws/apis/s3/v1beta1.Bucket",
Extractor: common.PathARNExtractor,
TerraformName: "aws_s3_bucket",
Extractor: common.PathARNExtractor,
}

r.References["redshift_configuration.s3_backup_configuration.bucket_arn"] = config.Reference{
Type: "github.com/upbound/provider-aws/apis/s3/v1beta1.Bucket",
Extractor: `github.com/crossplane/upjet/pkg/resource.ExtractParamPath("arn",true)`,
TerraformName: "aws_s3_bucket",
Extractor: common.PathARNExtractor,
}

config.MoveToStatus(r.TerraformResource, "arn")

r.LateInitializer = config.LateInitializer{
IgnoredFields: []string{
"server_side_encryption",
Expand Down
6 changes: 0 additions & 6 deletions package/crds/firehose.aws.upbound.io_deliverystreams.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,6 @@ spec:
type: string
forProvider:
properties:
arn:
description: The Amazon Resource Name (ARN) specifying the Stream
type: string
destination:
description: – This is the destination to where the data is delivered.
The only options are s3 (Deprecated, use extended_s3 instead),
Expand Down Expand Up @@ -4158,9 +4155,6 @@ spec:
for example because of an external controller is managing them, like an
autoscaler.
properties:
arn:
description: The Amazon Resource Name (ARN) specifying the Stream
type: string
destination:
description: – This is the destination to where the data is delivered.
The only options are s3 (Deprecated, use extended_s3 instead),
Expand Down

0 comments on commit affd2a0

Please sign in to comment.