Skip to content

Generate controller with aws-sdk-go-v2 #52

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions apis/v1alpha1/ack-generate-metadata.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
ack_generate_info:
build_date: "2025-01-23T02:21:19Z"
build_hash: 2442aa071c05fcdf54841e63abd5f91d1951e152
build_date: "2025-02-04T23:20:53Z"
build_hash: d2d639403dd853736e63c2bc1e3ca51251fd1bd1
go_version: go1.23.5
version: v0.41.0
api_directory_checksum: b055cc57ac2cc8b07e374803c280b65d1a72f3bf
version: v0.41.0-16-gd2d6394-dirty
api_directory_checksum: 78a5d23ba8b0c12225d1afd2506d5524d9a7aa68
api_version: v1alpha1
aws_sdk_go_version: v1.49.0
aws_sdk_go_version: v1.32.6
generator_config_info:
file_checksum: df0b4d7fe83a679c01131dc4af1844b5ff8105b3
file_checksum: 38b3144fc024675b7bdccb9141fc36779effb946
original_file_name: generator.yaml
last_modification:
reason: API generation
25 changes: 20 additions & 5 deletions apis/v1alpha1/certificate.go

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

86 changes: 43 additions & 43 deletions apis/v1alpha1/enums.go

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

11 changes: 7 additions & 4 deletions apis/v1alpha1/generator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,23 @@ resources:
# Unfortunately, because fields in the "ignore" configuration list are
# now deleted from the aws-sdk-go private/model/api.Shape object,
# setting `override_values` above does not work :(
code: input.SetValidationMethod("DNS")
code: input.ValidationMethod = "DNS"
sdk_read_one_pre_set_output:
template_path: hooks/certificate/sdk_read_one_pre_set_output.go.tpl
sdk_file_end:
template_path: hooks/certificate/sdk_file_end.go.tpl
late_initialize_post_read_one:
template_path: hooks/certificate/late_initialize_post_read_one.go.tpl
exceptions:
errors:
404:
code: ResourceNotFoundException
terminal_codes:
- InvalidParameter
- InvalidDomainValidationOptionsException
- InvalidParameterException
- InvalidDomainValidationOptionsException
- InvalidTagException
- TagPolicyException
- TooManyTagsException
- TooManyTagsException
- InvalidArnException
reconcile:
requeue_on_success_seconds: 60
Expand Down
16 changes: 8 additions & 8 deletions cmd/controller/main.go

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

25 changes: 20 additions & 5 deletions config/crd/bases/acm.services.k8s.aws_certificates.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -146,11 +146,26 @@ spec:
uses to encrypt data. RSA is the default key algorithm for ACM certificates.
Elliptic Curve Digital Signature Algorithm (ECDSA) keys are smaller, offering
security comparable to RSA keys but with greater computing efficiency. However,
ECDSA is not supported by all network clients. Some AWS services may require
RSA keys, or only support ECDSA keys of a particular size, while others allow
the use of either RSA and ECDSA keys to ensure that compatibility is not
broken. Check the requirements for the AWS service where you plan to deploy
your certificate.
ECDSA is not supported by all network clients. Some Amazon Web Services services
may require RSA keys, or only support ECDSA keys of a particular size, while
others allow the use of either RSA and ECDSA keys to ensure that compatibility
is not broken. Check the requirements for the Amazon Web Services service
where you plan to deploy your certificate. For more information about selecting
an algorithm, see Key algorithms (https://docs.aws.amazon.com/acm/latest/userguide/acm-certificate.html#algorithms).

Algorithms supported for an ACM certificate request include:

* RSA_2048

* EC_prime256v1

* EC_secp384r1

Other listed algorithms are for imported certificates only.

When you request a private PKI certificate signed by a CA from Amazon Web
Services Private CA, the specified signing algorithm family (RSA or ECDSA)
must match the algorithm family of the CA's secret key.

Default: RSA_2048
type: string
Expand Down
11 changes: 7 additions & 4 deletions generator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,23 @@ resources:
# Unfortunately, because fields in the "ignore" configuration list are
# now deleted from the aws-sdk-go private/model/api.Shape object,
# setting `override_values` above does not work :(
code: input.SetValidationMethod("DNS")
code: input.ValidationMethod = "DNS"
sdk_read_one_pre_set_output:
template_path: hooks/certificate/sdk_read_one_pre_set_output.go.tpl
sdk_file_end:
template_path: hooks/certificate/sdk_file_end.go.tpl
late_initialize_post_read_one:
template_path: hooks/certificate/late_initialize_post_read_one.go.tpl
exceptions:
errors:
404:
code: ResourceNotFoundException
terminal_codes:
- InvalidParameter
- InvalidDomainValidationOptionsException
- InvalidParameterException
- InvalidDomainValidationOptionsException
- InvalidTagException
- TagPolicyException
- TooManyTagsException
- TooManyTagsException
- InvalidArnException
reconcile:
requeue_on_success_seconds: 60
Expand Down
Loading