-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Adds resource BitbucketServerConfig to CloudBuild. #7083
Conversation
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 detailsYour assigned reviewer will help review your code by:
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. |
3aca578
to
f67f864
Compare
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 6 files changed, 1363 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed testsTestAccFirebaserulesRelease_BasicRelease|TestAccDatastreamStream_datastreamStreamFullExample|TestAccContainerCluster_withInvalidGatewayApiConfigChannel|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccDatastreamStream_update|TestAccCloudBuildBitbucketServerConfig_cloudbuildBitbucketServerConfigExample |
Tests passed during RECORDING mode: All tests passed |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 6 files changed, 1416 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed testsTestAccFirebaserulesRelease_BasicRelease |
cfc608b
to
9bd4e1b
Compare
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 6 files changed, 1503 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed testsTestAccRegionInstanceGroupManager_stateful|TestAccContainerCluster_failedCreation|TestAccCloudBuildBitbucketServerConfig_cloudbuildBitbucketServerConfigPeeredNetworkExample |
Tests passed during RECORDING mode: Tests failed during RECORDING mode: Please fix these to complete your PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, adding Shuya for a second review.
9bd4e1b
to
a166d74
Compare
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 6 files changed, 1503 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed testsTestAccFrameworkProviderMeta_setModuleName|TestAccRegionInstanceGroupManager_stateful|TestAccDataSourceDnsRecordSet_basic|TestAccApigeeAddonsConfig_apigeeAddonsTestExample |
Tests passed during RECORDING mode: Tests failed during RECORDING mode: Please fix these to complete your PR |
mmv1/products/cloudbuild/api.yaml
Outdated
description: | | ||
Immutable. The resource name for the webhook secret's secret version. Once this field has been set, it cannot be changed. | ||
If you need to change it, please create another BitbucketServerConfig. | ||
- !ruby/object:Api::Type::Time |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can omit the fields that may not be useful for Terraform users
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, removing createTime.
mmv1/products/cloudbuild/api.yaml
Outdated
name: 'BitbucketServerRepositoryId' | ||
description: | | ||
BitbucketServerRepositoryId identifies a specific repository hosted on a Bitbucket Server. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can remove these two lines. Don't think they will get generated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, yes, you are right. I assume you mean name as well? It looks like name and description are not generated. Removing both.
Immutable. API Key that will be attached to webhook. Once this field has been set, it cannot be changed. | ||
If you need to change it, please create another BitbucketServerConfig. | ||
- !ruby/object:Api::Type::Array | ||
name: 'connectedRepositories' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand that we probably not able to add tests for this field in our CI. Got a quick question regarding your local test:
- Have you tested the update functionality of this field?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did. I had to be sure to add custom code in the preupdate to remove this field from the field mask, as well as to then update it with custom code. Then made sure to test edge cases, 0 -> 1, many as well as update many, 1 -> 0, as well as a few other permutations.
description: | | ||
Time when the config was created. | ||
- !ruby/object:Api::Type::String | ||
name: 'username' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just want to confirm the behavior of this field. If we don't specify this field explicitly, will the API return a value for this field?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it needs this field from the user, it will return an error if not specified (it is the bitbucket server user name to be used by our api).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I missed required: true
setting somehow and thought it was an optional field, and that's why I asked the question. Thanks for confirming though!
terraform { | ||
required_providers { | ||
google = {} | ||
} | ||
} | ||
|
||
provider "google" {} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
any reason we need to set these explicitly?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope. Good catch, removing them.
2828778
to
76ff0c5
Compare
/gcbrun |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 6 files changed, 1472 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed testsTestAccFirebaserulesRelease_BasicRelease|TestAccApigeeAddonsConfig_apigeeAddonsTestExample|TestAccFrameworkProviderMeta_setModuleName|TestAccDataSourceDnsRecordSet_basic|TestAccDataSourceDnsManagedZone_basic |
Tests passed during RECORDING mode: Tests failed during RECORDING mode: Please fix these to complete your PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only some nitpicks and questions. Sorry for missing some of these in the previous review.
mmv1/templates/terraform/pre_update/cloudbuild_bitbucketserver_config.go.erb
Show resolved
Hide resolved
/gcbrun |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 6 files changed, 1472 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed testsTestAccFrameworkProviderMeta_setModuleName|TestAccApigeeAddonsConfig_apigeeAddonsTestExample|TestAccDataSourceDnsRecordSet_basic|TestAccDataSourceDnsManagedZone_basic |
Tests passed during RECORDING mode: Tests failed during RECORDING mode: Please fix these to complete your PR |
Co-authored-by: Shuya Ma <[email protected]>
Co-authored-by: Shuya Ma <[email protected]>
c6fc435
to
e9c40e1
Compare
/gcbrun |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 6 files changed, 1472 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed testsTestAccFirebaserulesRelease_BasicRelease|TestAccApigeeAddonsConfig_apigeeAddonsTestExample|TestAccFrameworkProviderMeta_setModuleName|TestAccDataSourceDnsRecordSet_basic|TestAccDataSourceDnsManagedZone_basic |
Tests passed during RECORDING mode: Tests failed during RECORDING mode: Please fix these to complete your PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the work!
Back to @trodge for final approval! |
…rm#7083) * Adds resource BitbucketServerConfig to CloudBuild. * Adds example bitbucket config with peered_network and ssl_ca fields being used * Minor code refactor. Removing unnecessary code for Cloud Build BitbucketServerConfig * Update doc description mmv1/products/cloudbuild/api.yaml Co-authored-by: Shuya Ma <[email protected]> * Update doc description mmv1/products/cloudbuild/api.yaml Co-authored-by: Shuya Ma <[email protected]> --------- Co-authored-by: Mario Machado <[email protected]> Co-authored-by: Shuya Ma <[email protected]>
…rm#7083) * Adds resource BitbucketServerConfig to CloudBuild. * Adds example bitbucket config with peered_network and ssl_ca fields being used * Minor code refactor. Removing unnecessary code for Cloud Build BitbucketServerConfig * Update doc description mmv1/products/cloudbuild/api.yaml Co-authored-by: Shuya Ma <[email protected]> * Update doc description mmv1/products/cloudbuild/api.yaml Co-authored-by: Shuya Ma <[email protected]> --------- Co-authored-by: Mario Machado <[email protected]> Co-authored-by: Shuya Ma <[email protected]>
Adds resource BitbucketServerConfig to CloudBuild.
If this PR is for Terraform, I acknowledge that I have:
make test
andmake lint
to ensure it passes unit and linter tests.Release Note Template for Downstream PRs (will be copied)