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

Add Organization/Project IAM Policy/Binding resources #661

Merged
merged 6 commits into from
Nov 2, 2023
Merged

Add Organization/Project IAM Policy/Binding resources #661

merged 6 commits into from
Nov 2, 2023

Conversation

dadgar
Copy link
Contributor

@dadgar dadgar commented Oct 31, 2023

🛠️ Description

Add Organization/Project IAM Policy/Binding resources:

  • data.hcp_iam_policy
  • hcp_organization_iam_policy
  • hcp_organization_iam_binding
  • hcp_project_iam_policy
  • hcp_project_iam_binding

These resources are implemented through a common interface that will allow us to extend the IAM resources to other objects in a consistent and performant way.

🏗️ Acceptance tests

  • Are there any feature flags that are required to use this functionality? No
  • Have you added an acceptance test for the functionality being added? Yes
  • Have you run the acceptance tests on this branch? Yes

Output from acceptance testing:

$ TF_ACC=1 go test -v
=== RUN   TestAccIAMPolicyDataSource
--- PASS: TestAccIAMPolicyDataSource (19.39s)
=== RUN   TestAccIAMPolicyDataSource_Validation
--- PASS: TestAccIAMPolicyDataSource_Validation (1.33s)
=== RUN   TestAccOrganizationDataSource
--- PASS: TestAccOrganizationDataSource (7.65s)
=== RUN   TestAccProjectDataSource
--- PASS: TestAccProjectDataSource (17.65s)
=== RUN   TestAccOrganizationIamBindingResource
--- PASS: TestAccOrganizationIamBindingResource (24.79s)
=== RUN   TestAccProjectIamPolicyResource
--- PASS: TestAccProjectIamPolicyResource (22.12s)
=== RUN   TestAccProjectIamBindingResource
--- PASS: TestAccProjectIamBindingResource (25.76s)
=== RUN   TestAccProjectResource
--- PASS: TestAccProjectResource (21.87s)
PASS
ok      github.com/hashicorp/terraform-provider-hcp/internal/provider/resourcemanager   141.000s

@dadgar dadgar requested review from a team as code owners October 31, 2023 03:06
Add:
* hcp_organization_iam_policy
* hcp_organization_iam_binding
* hcp_project_iam_policy
* hcp_project_iam_binding

These resources are implemented through a common interface that will
allow us to extend the IAM resources to other objects in a consistent
and performant way.
…but having the same value and not producing a plan diff. Also improve package documentation and layout
@dadgar dadgar merged commit 46ec29c into main Nov 2, 2023
@dadgar dadgar deleted the f-iam branch November 2, 2023 16:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants