From 959e581368e2a41b528f8d8a701e4c489215c9f5 Mon Sep 17 00:00:00 2001 From: irbekrm Date: Wed, 10 Feb 2021 13:29:05 +0000 Subject: [PATCH] Removes implementation-specific comment from api Co-authored-by: Richard Wall Signed-off-by: irbekrm --- deploy/crds/crd-certificates.yaml | 8 ++++---- pkg/apis/certmanager/v1/types_certificate.go | 3 +-- pkg/apis/certmanager/v1alpha2/types_certificate.go | 3 +-- pkg/apis/certmanager/v1alpha3/types_certificate.go | 3 +-- pkg/apis/certmanager/v1beta1/types_certificate.go | 3 +-- 5 files changed, 8 insertions(+), 12 deletions(-) diff --git a/deploy/crds/crd-certificates.yaml b/deploy/crds/crd-certificates.yaml index 1863287a1..6d7c8363a 100644 --- a/deploy/crds/crd-certificates.yaml +++ b/deploy/crds/crd-certificates.yaml @@ -132,7 +132,7 @@ spec: - pkcs1 - pkcs8 keySize: - description: KeySize is the key bit size of the corresponding private key for this certificate. If `keyAlgorithm` is set to `rsa`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `keyAlgorithm` is set to `ecdsa`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. Size validation is done by the validating webhook. + description: KeySize is the key bit size of the corresponding private key for this certificate. If `keyAlgorithm` is set to `rsa`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `keyAlgorithm` is set to `ecdsa`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. type: integer keystores: description: Keystores configures additional keystore output formats stored in the `secretName` Secret resource. @@ -427,7 +427,7 @@ spec: - pkcs1 - pkcs8 keySize: - description: KeySize is the key bit size of the corresponding private key for this certificate. If `keyAlgorithm` is set to `rsa`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `keyAlgorithm` is set to `ecdsa`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. Size validation is done by the validating webhook. + description: KeySize is the key bit size of the corresponding private key for this certificate. If `keyAlgorithm` is set to `rsa`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `keyAlgorithm` is set to `ecdsa`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. type: integer keystores: description: Keystores configures additional keystore output formats stored in the `secretName` Secret resource. @@ -779,7 +779,7 @@ spec: description: RotationPolicy controls how private keys should be regenerated when a re-issuance is being processed. If set to Never, a private key will only be generated if one does not already exist in the target `spec.secretName`. If one does exists but it does not have the correct algorithm or size, a warning will be raised to await user intervention. If set to Always, a private key matching the specified requirements will be generated whenever a re-issuance occurs. Default is 'Never' for backward compatibility. type: string size: - description: Size is the key bit size of the corresponding private key for this certificate. If `algorithm` is set to `RSA`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `algorithm` is set to `ECDSA`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. Size validation is done by the validating webhook. + description: Size is the key bit size of the corresponding private key for this certificate. If `algorithm` is set to `RSA`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `algorithm` is set to `ECDSA`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. type: integer renewBefore: description: The amount of time before the currently issued certificate's `notAfter` time that cert-manager will begin to attempt to renew the certificate. If this value is greater than the total duration of the certificate (i.e. notAfter - notBefore), it will be automatically renewed 2/3rds of the way through the certificate's duration. @@ -1076,7 +1076,7 @@ spec: description: RotationPolicy controls how private keys should be regenerated when a re-issuance is being processed. If set to Never, a private key will only be generated if one does not already exist in the target `spec.secretName`. If one does exists but it does not have the correct algorithm or size, a warning will be raised to await user intervention. If set to Always, a private key matching the specified requirements will be generated whenever a re-issuance occurs. Default is 'Never' for backward compatibility. type: string size: - description: Size is the key bit size of the corresponding private key for this certificate. If `algorithm` is set to `RSA`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `algorithm` is set to `ECDSA`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. Size validation is done by the validating webhook. + description: Size is the key bit size of the corresponding private key for this certificate. If `algorithm` is set to `RSA`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `algorithm` is set to `ECDSA`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. No other values are allowed. type: integer renewBefore: description: The amount of time before the currently issued certificate's `notAfter` time that cert-manager will begin to attempt to renew the certificate. If this value is greater than the total duration of the certificate (i.e. notAfter - notBefore), it will be automatically renewed 2/3rds of the way through the certificate's duration. diff --git a/pkg/apis/certmanager/v1/types_certificate.go b/pkg/apis/certmanager/v1/types_certificate.go index 39a0d8258..1a5516e8f 100644 --- a/pkg/apis/certmanager/v1/types_certificate.go +++ b/pkg/apis/certmanager/v1/types_certificate.go @@ -205,9 +205,8 @@ type CertificatePrivateKey struct { // If `algorithm` is set to `ECDSA`, valid values are `256`, `384` or `521`, // and will default to `256` if not specified. // No other values are allowed. - // Size validation is done by the validating webhook. // +optional - Size int `json:"size,omitempty"` + Size int `json:"size,omitempty"` // Validated by webhook. Be mindful of adding OpenAPI validation- see https://github.com/jetstack/cert-manager/issues/3644 } // Denotes how private keys should be generated or sourced when a Certificate diff --git a/pkg/apis/certmanager/v1alpha2/types_certificate.go b/pkg/apis/certmanager/v1alpha2/types_certificate.go index 5a8f54cab..87a2c2ae5 100644 --- a/pkg/apis/certmanager/v1alpha2/types_certificate.go +++ b/pkg/apis/certmanager/v1alpha2/types_certificate.go @@ -163,9 +163,8 @@ type CertificateSpec struct { // If `keyAlgorithm` is set to `ecdsa`, valid values are `256`, `384` or `521`, // and will default to `256` if not specified. // No other values are allowed. - // Size validation is done by the validating webhook. // +optional - KeySize int `json:"keySize,omitempty"` + KeySize int `json:"keySize,omitempty"` // Validated by webhook. Be mindful of adding OpenAPI validation- see https://github.com/jetstack/cert-manager/issues/3644 . // KeyAlgorithm is the private key algorithm of the corresponding private key // for this certificate. If provided, allowed values are either `rsa` or `ecdsa` diff --git a/pkg/apis/certmanager/v1alpha3/types_certificate.go b/pkg/apis/certmanager/v1alpha3/types_certificate.go index e6547af4d..51a2619f5 100644 --- a/pkg/apis/certmanager/v1alpha3/types_certificate.go +++ b/pkg/apis/certmanager/v1alpha3/types_certificate.go @@ -161,9 +161,8 @@ type CertificateSpec struct { // If `keyAlgorithm` is set to `ecdsa`, valid values are `256`, `384` or `521`, // and will default to `256` if not specified. // No other values are allowed. - // Size validation is done by the validating webhook. // +optional - KeySize int `json:"keySize,omitempty"` + KeySize int `json:"keySize,omitempty"` // Validated by webhook. Be mindful of adding OpenAPI validation- see https://github.com/jetstack/cert-manager/issues/3644 . // KeyAlgorithm is the private key algorithm of the corresponding private key // for this certificate. If provided, allowed values are either `rsa` or `ecdsa` diff --git a/pkg/apis/certmanager/v1beta1/types_certificate.go b/pkg/apis/certmanager/v1beta1/types_certificate.go index b492dbac6..06fca40d5 100644 --- a/pkg/apis/certmanager/v1beta1/types_certificate.go +++ b/pkg/apis/certmanager/v1beta1/types_certificate.go @@ -204,9 +204,8 @@ type CertificatePrivateKey struct { // If `algorithm` is set to `ECDSA`, valid values are `256`, `384` or `521`, // and will default to `256` if not specified. // No other values are allowed. - // Size validation is done by the validating webhook. // +optional - Size int `json:"size,omitempty"` + Size int `json:"size,omitempty"` // Validated by webhook. Be mindful of adding OpenAPI validation- see https://github.com/jetstack/cert-manager/issues/3644 . } // Denotes how private keys should be generated or sourced when a Certificate