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

Clean up IAM Scopes in the documentation #4321

Merged
merged 11 commits into from
Dec 16, 2020

Conversation

upodroid
Copy link
Contributor

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

  • Searched through the issue tracker for an open issue that this either resolves or contributes to, commented on it to claim it, and written "fixes {url}" or "part of {url}" in this PR description. If there were no relevant open issues, I opened one and commented that I would like to work on it (not necessary for very small changes).
  • Generated Terraform, and ran make test and make lint to ensure it passes unit and linter tests.
  • Ensured that all new fields I added that can be set by a user appear in at least one example (for generated resources) or third_party test (for handwritten resources or update tests).
  • Ran relevant acceptance tests (If the acceptance tests do not yet pass or you are unable to run them, please let your reviewer know).
  • Read the Release Notes Guide before writing my release note below.

Release Note Template for Downstream PRs (will be copied)


@google-cla google-cla bot added the cla: yes label Dec 15, 2020
@modular-magician
Copy link
Collaborator

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

I have detected that you are a community contributor, so your PR will be assigned to someone with a commit-bit on this repo for initial review.

Thanks for your contribution! A human will be with you soon.

@melinath, please review this PR or find an appropriate assignee.

@upodroid
Copy link
Contributor Author

This issue should be closed hashicorp/terraform-provider-google#1943

@@ -10,8 +10,6 @@ import (
"github.com/hashicorp/terraform-plugin-sdk/v2/terraform"
)
<%
# raise 'skip_import_test should be true if resource is not importable' \
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Follow up from #4273

@upodroid
Copy link
Contributor Author

upodroid commented Dec 15, 2020

@rileykarson while i'm cleaning up legacy scopes, can i remove compute, devstorage and clouddns in a minor release from the snippet below given that cloud-platform supercedes them?

https://github.com/hashicorp/terraform-provider-google/blob/179ede2188a1c16c3d17dd7e3099b616297000d8/google/config.go#L219

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 8 files changed, 48 insertions(+), 119 deletions(-))
Terraform Beta: Diff ( 8 files changed, 48 insertions(+), 119 deletions(-))

Copy link
Member

@rileykarson rileykarson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@upodroid: Can you file an issue? I don't want to change the declared list of scopes outside of a major version, particularly if we're removing any.

"https://www.googleapis.com/auth/cloud-platform"
]
}
}
```

## Example Usage - with the default node pool
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

drive-by: This + the node pool example being removed are intentional and should be kept, even if they don't fit the best practices for configuring the resource. While we'd prefer users configure resources using the recommended setups, I'd rather we provide clear documentation on what alternatives look like vs forcing users to experiment themselves.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll revert this change for both resources.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The GKE resource is such a mess. There are so many open breaking change issues for it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a busy resource!

Co-authored-by: upodroid <cy@borg.dev>
@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 8 files changed, 68 insertions(+), 78 deletions(-))
Terraform Beta: Diff ( 9 files changed, 69 insertions(+), 79 deletions(-))

Copy link
Member

@melinath melinath left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM for the most part - I have a few questions, and one suggested change to the new standard language explaining service account usage.

Copy link
Member

@melinath melinath left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm - thanks!

@melinath melinath merged commit f7f0426 into GoogleCloudPlatform:master Dec 16, 2020
@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 8 files changed, 68 insertions(+), 78 deletions(-))
Terraform Beta: Diff ( 8 files changed, 68 insertions(+), 78 deletions(-))

@melinath
Copy link
Member

@upodroid I ran into an issue where using the service account names in the new documentation causes an error because of the use of _ instead of -. Is there any chance you would be able to put together a follow-up PR switching those over?

Error: "account_id" ("service_account_id") doesn't match regexp "^[a-z](?:[-a-z0-9]{4,28}[a-z0-9])$"

@upodroid
Copy link
Contributor Author

Hmm, which example was that?

@upodroid
Copy link
Contributor Author

nvm, underscores are illegal in service account names

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants