Skip to content
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

Image storage location #7943

Merged
merged 6 commits into from
May 16, 2023
Merged

Image storage location #7943

merged 6 commits into from
May 16, 2023

Conversation

shubhamkr619
Copy link
Contributor

@shubhamkr619 shubhamkr619 commented May 15, 2023

Fixes: hashicorp/terraform-provider-google#6082

Recreated the PR as deleting the branch closed the old PR i.e. #7378

This is the PR to support StorageLocation for Image resource. This shall allow users to select the region and supply that as a list.
However, this PR could not be tested because of the error : hashicorp/terraform-provider-google#13846

If this PR is for Terraform, I acknowledge that I have:

Release Note Template for Downstream PRs (will be copied)

* Added support for storageLocation in Image resource 

@modular-magician
Copy link
Collaborator

Hello! I am a robot who works on Magic Modules PRs.

I've detected that you're a community contributor. @trodge, a repository maintainer, has been assigned to assist you and help review your changes.

❓ First time contributing? Click here for more details

Your assigned reviewer will help review your code by:

  • Ensuring it's backwards compatible, covers common error cases, etc.
  • Summarizing the change into a user-facing changelog note.
  • Passes tests, either our "VCR" suite, a set of presubmit tests, or with manual test runs.

You can help make sure that review is quick by running local tests and ensuring they're passing in between each push you make to your PR's branch. Also, try to leave a comment with each push you make, as pushes generally don't generate emails.

If your reviewer doesn't get back to you within a week after your most recent change, please feel free to leave a comment on the issue asking them to take a look! In the absence of a dedicated review dashboard most maintainers manage their pending reviews through email, and those will sometimes get lost in their inbox.


@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 3 files changed, 90 insertions(+))
Terraform Beta: Diff ( 3 files changed, 90 insertions(+))
TF Conversion: Diff ( 3 files changed, 13 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 4 files changed, 109 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2736
Passed tests 2419
Skipped tests: 283
Affected tests: 34

Action taken

Found 34 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeRegionInstanceTemplate_sourceImageEncryptionKey|TestAccComputeRegionInstanceTemplate_nictype_update|TestAccComputeRegionInstanceTemplate_imageShorthand|TestAccComputeInstance_nictype_update|TestAccComputeImageIamPolicyGenerated_withCondition|TestAccComputeInstanceTemplate_imageShorthand|TestAccComputeInstance_networkPerformanceConfig|TestAccComputeInstance_private_image_family|TestAccComputeImage_resolveImage|TestAccComputeImage_sourceSnapshot|TestAccComputeImage_sourceImage|TestAccComputeImage_update|TestAccComputeImage_imageBasicStorageLocationExample|TestAccComputeImage_withLicense|TestAccComputeImage_imageGuestOsExample|TestAccComputeImage_imageBasicExample|TestAccComputeImage_basedondisk|TestAccComputeInstanceTemplate_sourceImageEncryptionKey|TestAccComputeImage_imageEncryptionKey|TestAccComputeInstanceTemplate_nictype_update|TestAccComputeFirewallPolicyRule_multipleRules|TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample|TestAccAlloydbBackup_missingLocation|TestAccAlloydbCluster_missingLocation|TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example|TestAccComputeImageIamMemberGenerated_withCondition|TestAccComputeImageIamBindingGenerated_withCondition|TestAccComputeImageIamPolicyGenerated|TestAccComputeImageIamMemberGenerated|TestAccComputeImageIamBindingGenerated|TestAccDataSourceGoogleFirebaseAndroidAppConfig|TestAccDataSourceAlloydbLocations_basic|TestAccDataSourceComputeImage|TestAccDataSourceComputeImageFilter

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample[Debug log]
TestAccAlloydbBackup_missingLocation[Debug log]
TestAccAlloydbCluster_missingLocation[Debug log]
TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example[Debug log]
TestAccDataSourceGoogleFirebaseAndroidAppConfig[Debug log]
TestAccDataSourceAlloydbLocations_basic[Debug log]

Tests failed during RECORDING mode:
TestAccComputeRegionInstanceTemplate_sourceImageEncryptionKey[Error message] [Debug log]
TestAccComputeRegionInstanceTemplate_nictype_update[Error message] [Debug log]
TestAccComputeRegionInstanceTemplate_imageShorthand[Error message] [Debug log]
TestAccComputeInstance_nictype_update[Error message] [Debug log]
TestAccComputeImageIamPolicyGenerated_withCondition[Error message] [Debug log]
TestAccComputeInstanceTemplate_imageShorthand[Error message] [Debug log]
TestAccComputeInstance_networkPerformanceConfig[Error message] [Debug log]
TestAccComputeInstance_private_image_family[Error message] [Debug log]
TestAccComputeImage_resolveImage[Error message] [Debug log]
TestAccComputeImage_sourceSnapshot[Error message] [Debug log]
TestAccComputeImage_sourceImage[Error message] [Debug log]
TestAccComputeImage_update[Error message] [Debug log]
TestAccComputeImage_imageBasicStorageLocationExample[Error message] [Debug log]
TestAccComputeImage_withLicense[Error message] [Debug log]
TestAccComputeImage_imageGuestOsExample[Error message] [Debug log]
TestAccComputeImage_imageBasicExample[Error message] [Debug log]
TestAccComputeImage_basedondisk[Error message] [Debug log]
TestAccComputeInstanceTemplate_sourceImageEncryptionKey[Error message] [Debug log]
TestAccComputeImage_imageEncryptionKey[Error message] [Debug log]
TestAccComputeInstanceTemplate_nictype_update[Error message] [Debug log]
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]
TestAccComputeImageIamMemberGenerated_withCondition[Error message] [Debug log]
TestAccComputeImageIamBindingGenerated_withCondition[Error message] [Debug log]
TestAccComputeImageIamPolicyGenerated[Error message] [Debug log]
TestAccComputeImageIamMemberGenerated[Error message] [Debug log]
TestAccComputeImageIamBindingGenerated[Error message] [Debug log]
TestAccDataSourceComputeImage[Error message] [Debug log]
TestAccDataSourceComputeImageFilter[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 3 files changed, 91 insertions(+))
Terraform Beta: Diff ( 3 files changed, 91 insertions(+))
TF Conversion: Diff ( 3 files changed, 13 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 4 files changed, 109 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2740
Passed tests 2449
Skipped tests: 283
Affected tests: 8

Action taken

Found 8 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccDataSourceGoogleFirebaseAndroidAppConfig|TestAccDataSourceAlloydbLocations_basic|TestAccComputeImage_imageBasicStorageLocationExample|TestAccComputeFirewallPolicyRule_multipleRules|TestAccAlloydbBackup_missingLocation|TestAccAlloydbCluster_missingLocation|TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample|TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccDataSourceAlloydbLocations_basic[Debug log]
TestAccAlloydbBackup_missingLocation[Debug log]
TestAccAlloydbCluster_missingLocation[Debug log]
TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample[Debug log]
TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example[Debug log]

Tests failed during RECORDING mode:
TestAccDataSourceGoogleFirebaseAndroidAppConfig[Error message] [Debug log]
TestAccComputeImage_imageBasicStorageLocationExample[Error message] [Debug log]
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@shubhamkr619
Copy link
Contributor Author

@trodge , it seems like the job is completed in 1:08 hours, however it shows failed here. https://pantheon.corp.google.com/cloud-build/builds;region=global/28c76c93-1186-4a11-affe-461208b05e1a;step=22?mods=logs_tg_prod&project=graphite-docker-images

Is there any way to confirm that it failed?

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 3 files changed, 91 insertions(+))
Terraform Beta: Diff ( 3 files changed, 91 insertions(+))
TF Conversion: Diff ( 3 files changed, 13 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 4 files changed, 109 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2741
Passed tests 2450
Skipped tests: 283
Affected tests: 8

Action taken

Found 8 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccDataSourceGoogleFirebaseAndroidAppConfig|TestAccComputeImage_imageBasicStorageLocationExample|TestAccDataSourceAlloydbLocations_basic|TestAccAlloydbBackup_missingLocation|TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example|TestAccAlloydbCluster_missingLocation|TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample|TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccDataSourceGoogleFirebaseAndroidAppConfig[Debug log]
TestAccDataSourceAlloydbLocations_basic[Debug log]
TestAccAlloydbBackup_missingLocation[Debug log]
TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example[Debug log]
TestAccAlloydbCluster_missingLocation[Debug log]
TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample[Debug log]

Tests failed during RECORDING mode:
TestAccComputeImage_imageBasicStorageLocationExample[Error message] [Debug log]
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 3 files changed, 91 insertions(+))
Terraform Beta: Diff ( 3 files changed, 91 insertions(+))
TF Conversion: Diff ( 3 files changed, 13 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 4 files changed, 109 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2741
Passed tests 2450
Skipped tests: 283
Affected tests: 8

Action taken

Found 8 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeImage_imageBasicStorageLocationExample|TestAccComputeFirewallPolicyRule_multipleRules|TestAccAlloydbCluster_missingLocation|TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample|TestAccAlloydbBackup_missingLocation|TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example|TestAccDataSourceGoogleFirebaseAndroidAppConfig|TestAccDataSourceAlloydbLocations_basic

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccComputeImage_imageBasicStorageLocationExample[Debug log]
TestAccAlloydbCluster_missingLocation[Debug log]
TestAccApigeeKeystoresAliasesKeyCertFile_apigeeKeystoresAliasesKeyCertFileTestExample[Debug log]
TestAccAlloydbBackup_missingLocation[Debug log]
TestAccApigeeKeystoresAliasesPkcs12_ApigeeKeystoresAliasesPkcs12Example[Debug log]
TestAccDataSourceGoogleFirebaseAndroidAppConfig[Debug log]
TestAccDataSourceAlloydbLocations_basic[Debug log]

Tests failed during RECORDING mode:
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@shubhamkr619
Copy link
Contributor Author

@trodge , the current error is because of quota exceed for firewall that has nothing to do with this change.

2023/05/15 23:48:30 [DEBUG] [transport] transport: loopyWriter exiting with error: transport closed by client 
    vcr_utils.go:145: Step 4/6 error: Error running apply: exit status 1
        
        Error: Error creating FirewallPolicyRule: operation received error: error code "QUOTA_EXCEEDED", message: Quota 'FIREWALL_SECURITY_POLICY_RULES' exceeded.  Limit: 250.0 globally.
        
        
          with google_compute_firewall_policy_rule.rule3,
          on terraform_plugin_test.tf line 67, in resource "google_compute_firewall_policy_rule" "rule3":
          67: resource "google_compute_firewall_policy_rule" "rule3" {

@trodge trodge merged commit f913b63 into GoogleCloudPlatform:main May 16, 2023
16 of 17 checks passed
shourya116 pushed a commit to shourya116/magic-modules that referenced this pull request May 25, 2023
* update code to follow latest structure

* storagelocation api adding default_from_api

* updated the location api to use US

* fix resource name

* fix resource name and image name

* updated the storage location option

---------

Co-authored-by: Shubham Singh <skshubham@google.com>
ericayyliu pushed a commit to ericayyliu/magic-modules that referenced this pull request Jul 26, 2023
* update code to follow latest structure

* storagelocation api adding default_from_api

* updated the location api to use US

* fix resource name

* fix resource name and image name

* updated the storage location option

---------

Co-authored-by: Shubham Singh <skshubham@google.com>
wj-chen pushed a commit to wj-chen/magic-modules that referenced this pull request Aug 1, 2023
* update code to follow latest structure

* storagelocation api adding default_from_api

* updated the location api to use US

* fix resource name

* fix resource name and image name

* updated the storage location option

---------

Co-authored-by: Shubham Singh <skshubham@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants