diff --git a/.changelog/5436.txt b/.changelog/5436.txt new file mode 100644 index 0000000000..084e4847ea --- /dev/null +++ b/.changelog/5436.txt @@ -0,0 +1,3 @@ +```release-note:bug +privateca: fixed crlAccessUrls in `CertificateAuthority ` +``` diff --git a/google-beta/resource_privateca_certificate_authority.go b/google-beta/resource_privateca_certificate_authority.go index 9c3dc72656..d385e4796a 100644 --- a/google-beta/resource_privateca_certificate_authority.go +++ b/google-beta/resource_privateca_certificate_authority.go @@ -533,11 +533,14 @@ issue certificates. Default value: "SELF_SIGNED" Possible values: ["SELF_SIGNED" Description: `The URL where this CertificateAuthority's CA certificate is published. This will only be set for CAs that have been activated.`, }, - "crl_access_url": { - Type: schema.TypeString, + "crl_access_urls": { + Type: schema.TypeList, Computed: true, Description: `The URL where this CertificateAuthority's CRLs are published. This will only be set for CAs that have been activated.`, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, }, }, }, @@ -1101,15 +1104,15 @@ func flattenPrivatecaCertificateAuthorityAccessUrls(v interface{}, d *schema.Res transformed := make(map[string]interface{}) transformed["ca_certificate_access_url"] = flattenPrivatecaCertificateAuthorityAccessUrlsCaCertificateAccessUrl(original["caCertificateAccessUrl"], d, config) - transformed["crl_access_url"] = - flattenPrivatecaCertificateAuthorityAccessUrlsCrlAccessUrl(original["crlAccessUrl"], d, config) + transformed["crl_access_urls"] = + flattenPrivatecaCertificateAuthorityAccessUrlsCrlAccessUrls(original["crlAccessUrls"], d, config) return []interface{}{transformed} } func flattenPrivatecaCertificateAuthorityAccessUrlsCaCertificateAccessUrl(v interface{}, d *schema.ResourceData, config *Config) interface{} { return v } -func flattenPrivatecaCertificateAuthorityAccessUrlsCrlAccessUrl(v interface{}, d *schema.ResourceData, config *Config) interface{} { +func flattenPrivatecaCertificateAuthorityAccessUrlsCrlAccessUrls(v interface{}, d *schema.ResourceData, config *Config) interface{} { return v } diff --git a/website/docs/r/privateca_certificate_authority.html.markdown b/website/docs/r/privateca_certificate_authority.html.markdown index 4bad63357f..bd4ff691ef 100644 --- a/website/docs/r/privateca_certificate_authority.html.markdown +++ b/website/docs/r/privateca_certificate_authority.html.markdown @@ -577,7 +577,7 @@ In addition to the arguments listed above, the following computed attributes are The URL where this CertificateAuthority's CA certificate is published. This will only be set for CAs that have been activated. -* `crl_access_url` - +* `crl_access_urls` - The URL where this CertificateAuthority's CRLs are published. This will only be set for CAs that have been activated.