Fixed an issue which force optional field is_ca in Certificate to be set
b/345539403
The semantic of is_ca for Certificate in terraform is
- If
ca_optionsis not specified at all (enabled by this PR) ORca_options {non_ca=true}is specified- a certificate will be issued with a basicConstraints ext(is_ca=false)
- if
ca_options {}is specified, a certificate will be issued without a basicConstraints ext. - if
ca_options {is_ca=true}is specified, a certificate will be issued with a basicConstraints ext (is_ca=true).
Release Note Template for Downstream PRs (will be copied)
privateca: fixed an issue which force optional field is_ca in Certificate to be set
Hi there, I'm the Modular magician. I've detected the following information about your changes:
Diff report
Your PR generated some diffs in downstreams - here they are.
google provider: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
google-beta provider: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
terraform-google-conversion: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
Tests analytics
Total tests: 39
Passed tests: 31
Skipped tests: 7
Affected tests: 1
Click here to see the affected service packages
- privateca
Action taken
Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccPrivatecaCaPool_privatecaCapoolEmptyBaseline
$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccPrivatecaCaPool_privatecaCapoolEmptyBaseline[Error message] [Debug log]
$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$ View the build log or the debug log for each test
Hi there, I'm the Modular magician. I've detected the following information about your changes:
Diff report
Your PR generated some diffs in downstreams - here they are.
google provider: Diff ( 4 files changed, 20 insertions(+), 13 deletions(-))
google-beta provider: Diff ( 4 files changed, 20 insertions(+), 13 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
Hi there, I'm the Modular magician. I've detected the following information about your changes:
Diff report
Your PR generated some diffs in downstreams - here they are.
google provider: Diff ( 4 files changed, 20 insertions(+), 13 deletions(-))
google-beta provider: Diff ( 4 files changed, 20 insertions(+), 13 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
Tests analytics
Total tests: 39
Passed tests: 25
Skipped tests: 7
Affected tests: 7
Click here to see the affected service packages
- privateca
Action taken
Found 7 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccPrivatecaCaPool_privatecaCapoolEmptyBaseline|TestAccPrivatecaCertificate_privatecaCertificateConfigExample|TestAccPrivatecaCertificate_privatecaCertificateCsrExample|TestAccPrivatecaCertificate_privatecaCertificateCustomSkiExample|TestAccPrivatecaCertificate_privatecaCertificateNoAuthorityExample|TestAccPrivatecaCertificate_privatecaCertificateUpdate|TestAccPrivatecaCertificate_privatecaCertificateWithTemplateExample
$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccPrivatecaCaPool_privatecaCapoolEmptyBaseline[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateConfigExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateCsrExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateCustomSkiExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateNoAuthorityExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateWithTemplateExample[Debug log]
$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$
$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccPrivatecaCertificate_privatecaCertificateUpdate[Error message] [Debug log]
$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$ View the build log or the debug log for each test
Tests analytics
Total tests: 39
Passed tests: 25
Skipped tests: 7
Affected tests: 7
Click here to see the affected service packages
- privateca
Action taken
Found 7 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccPrivatecaCaPool_privatecaCapoolEmptyBaseline|TestAccPrivatecaCertificate_privatecaCertificateConfigExample|TestAccPrivatecaCertificate_privatecaCertificateCsrExample|TestAccPrivatecaCertificate_privatecaCertificateCustomSkiExample|TestAccPrivatecaCertificate_privatecaCertificateNoAuthorityExample|TestAccPrivatecaCertificate_privatecaCertificateUpdate|TestAccPrivatecaCertificate_privatecaCertificateWithTemplateExample
$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccPrivatecaCaPool_privatecaCapoolEmptyBaseline[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateConfigExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateCsrExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateCustomSkiExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateNoAuthorityExample[Debug log]
TestAccPrivatecaCertificate_privatecaCertificateWithTemplateExample[Debug log]
$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$
$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccPrivatecaCertificate_privatecaCertificateUpdate[Error message] [Debug log]
$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$ View the build log or the debug log for each test
Hello! I am a robot. Tests will require approval from a repository maintainer to run.
@shuyama1, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.
You can help make sure that review is quick by doing a self-review and by running impacted tests locally.
@shuyama1 This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.
I think the failing test
TestAccPrivatecaCertificate_privatecaCertificateUpdateis related. The test failed due to error:vcr_utils.go:152: Step 3/6 error: Error running pre-apply refresh: exit status 1 Error: Provider produced invalid plan Provider "registry.terraform.io/hashicorp/google" has indicated "requires replacement" on google_privateca_certificate.default for a non-existent attribute path cty.Path{cty.GetAttrStep{Name:"config"}, cty.IndexStep{Key:cty.NumberIntVal(0)}, cty.GetAttrStep{Name:"x509_config"}, cty.IndexStep{Key:cty.NumberIntVal(0)}, cty.GetAttrStep{Name:"ca_options"}, cty.IndexStep{Key:cty.NumberIntVal(0)}, cty.GetAttrStep{Name:"is_ca"}}. This is a bug in the provider, which should be reported in the provider's own issue tracker.
The test passed when running it locally. Do you think it could due to the limitation from RECORDING mode?
It shouldn't be affected by running in VCR, especially in recording mode, as it's just running the actual acceptance test. Let me re-run the test for now, and if it fails again, I'll need to look a bit closer into the failure.
/gcbrun
Hi there, I'm the Modular magician. I've detected the following information about your changes:
Diff report
Your PR generated some diffs in downstreams - here they are.
google provider: Diff ( 4 files changed, 20 insertions(+), 13 deletions(-))
google-beta provider: Diff ( 4 files changed, 20 insertions(+), 13 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
Tests analytics
Total tests: 39
Passed tests: 31
Skipped tests: 7
Affected tests: 1
Click here to see the affected service packages
- privateca
Action taken
Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccPrivatecaCertificate_privatecaCertificateUpdate
$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccPrivatecaCertificate_privatecaCertificateUpdate[Error message] [Debug log]
$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$ View the build log or the debug log for each test
@shuyama1 This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.
@GoogleCloudPlatform/terraform-team @shuyama1 This PR has been waiting for review for 1 week. Please take a look! Use the label disable-review-reminders to disable these notifications.
Hi there, I'm the Modular magician. I've detected the following information about your changes:
Diff report
Your PR generated some diffs in downstreams - here they are.
google provider: Diff ( 5 files changed, 20 insertions(+), 19 deletions(-))
google-beta provider: Diff ( 5 files changed, 20 insertions(+), 19 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
Tests analytics
Total tests: 63 Passed tests: 31 Skipped tests: 7 Affected tests: 1
Click here to see the affected service packages
- privateca
Action taken
Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
- TestAccPrivatecaCertificate_privatecaCertificateUpdate
$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccPrivatecaCertificate_privatecaCertificateUpdate[Debug log]
$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$
$\textcolor{green}{\textsf{All tests passed!}}$
@shuyama1 This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.
@gfxcc, this PR is waiting for action from you. Please address any comments or change requests, or re-request review from a core reviewer if no action is required.

If no action is taken, this PR will be closed in 28 days.
This notification can be disabled with the disable-automatic-closure label.
Just want to confirm I understand the cases correctly -
- omitting the
ca_optionsblock in Terraform would be the same as settingca_options {non_ca=true}, which means we will sendCaOptions {is_ca=false}to the API.
Correct. The requests are different (omitting ca_options vs CaOptions {is_ca=false}), but result to the same behavior.
- omitting the
ca_optionsblock is different from explicitly set it as a empty blockca_options {}in Terraform, as the latter means CaOptions {} (is_ca unspecified) to the API?
Correct. Those 2 config has different meaning to the API.
The new behaviors are listed in the PR description.
@shuyama1 This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.
Sorry for the delay on review. I'll be taking a look later today.
@GoogleCloudPlatform/terraform-team @shuyama1 This PR has been waiting for review for 1 week. Please take a look! Use the label disable-review-reminders to disable these notifications.
/gcbrun
Hi there, I'm the Modular magician. I've detected the following information about your changes:
Diff report
Your PR generated some diffs in downstreams - here they are.
google provider: Diff ( 5 files changed, 20 insertions(+), 19 deletions(-))
google-beta provider: Diff ( 5 files changed, 20 insertions(+), 19 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 5 insertions(+), 1 deletion(-))
Tests analytics
Total tests: 39 Passed tests: 32 Skipped tests: 7 Affected tests: 0
Click here to see the affected service packages
- privateca
$\textcolor{green}{\textsf{All tests passed!}}$
View the build log