-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
service/guardduty: Support GuardDuty Organizations #13034
Conversation
Reference: #13005 Reference: #13006 Changes: ``` FEATURES: * **New Resource:** `aws_guardduty_organization_admin_account` * **New Resource:** `aws_guardduty_organization_configuration` ``` Output from acceptance testing: ``` --- PASS: TestAccAWSGuardDuty (137.70s) --- PASS: TestAccAWSGuardDuty/Detector (58.97s) --- PASS: TestAccAWSGuardDuty/Detector/basic (41.45s) --- PASS: TestAccAWSGuardDuty/Detector/import (17.52s) --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount (31.74s) --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount/basic (31.74s) --- PASS: TestAccAWSGuardDuty/OrganizationConfiguration (46.99s) --- PASS: TestAccAWSGuardDuty/OrganizationConfiguration/basic (46.99s) ```
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.
A couple comments, otherwise LGTM 🚀
--- PASS: TestAccAWSGuardDuty (129.63s)
--- PASS: TestAccAWSGuardDuty/OrganizationConfiguration (1.07s)
--- SKIP: TestAccAWSGuardDuty/OrganizationConfiguration/basic (1.07s)
--- PASS: TestAccAWSGuardDuty/ThreatIntelSet (34.41s)
--- PASS: TestAccAWSGuardDuty/ThreatIntelSet/basic (21.10s)
--- PASS: TestAccAWSGuardDuty/ThreatIntelSet/import (13.32s)
--- PASS: TestAccAWSGuardDuty/Member (10.06s)
--- PASS: TestAccAWSGuardDuty/Member/basic (10.06s)
--- SKIP: TestAccAWSGuardDuty/Member/inviteOnUpdate (0.00s)
--- SKIP: TestAccAWSGuardDuty/Member/inviteDisassociate (0.00s)
--- SKIP: TestAccAWSGuardDuty/Member/invitationMessage (0.00s)
--- PASS: TestAccAWSGuardDuty/Detector (49.98s)
--- PASS: TestAccAWSGuardDuty/Detector/basic (27.82s)
--- PASS: TestAccAWSGuardDuty/Detector/datasource_basic (12.88s)
--- PASS: TestAccAWSGuardDuty/Detector/datasource_id (9.28s)
--- PASS: TestAccAWSGuardDuty/InviteAccepter (0.00s)
--- SKIP: TestAccAWSGuardDuty/InviteAccepter/basic (0.00s)
--- PASS: TestAccAWSGuardDuty/IPSet (33.09s)
--- PASS: TestAccAWSGuardDuty/IPSet/import (13.31s)
--- PASS: TestAccAWSGuardDuty/IPSet/basic (19.78s)
--- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount (1.02s)
--- SKIP: TestAccAWSGuardDuty/OrganizationAdminAccount/basic (1.02s)
|
||
if aws.StringValue(adminAccount.AdminAccountId) == adminAccountID { | ||
result = adminAccount | ||
break |
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.
Since we've found the result here, we could return false
to stop iterating pages
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.
Good catch! Yes, we should return there. 👍
} | ||
|
||
if _, err := waiter.AdminAccountNotFound(conn, d.Id()); err != nil { | ||
return fmt.Errorf("error waiting for GuardDuty Organization Admin Account (%s) disable: %w", d.Id(), err) |
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.
Nit: to disable
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.
Thanks! Will update that. 👍
…comments Reference: #13034 (review) Output from acceptance testing: ``` --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount (44.91s) --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount/basic (44.91s) ```
Acceptance testing good after returning early:
Will merge tomorrow if CI looks good still. 👍 |
This has been released in version 2.60.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template for triage. Thanks! |
* service/guardduty: Support GuardDuty Organizations Reference: hashicorp#13005 Reference: hashicorp#13006 Changes: ``` FEATURES: * **New Resource:** `aws_guardduty_organization_admin_account` * **New Resource:** `aws_guardduty_organization_configuration` ``` Output from acceptance testing: ``` --- PASS: TestAccAWSGuardDuty (137.70s) --- PASS: TestAccAWSGuardDuty/Detector (58.97s) --- PASS: TestAccAWSGuardDuty/Detector/basic (41.45s) --- PASS: TestAccAWSGuardDuty/Detector/import (17.52s) --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount (31.74s) --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount/basic (31.74s) --- PASS: TestAccAWSGuardDuty/OrganizationConfiguration (46.99s) --- PASS: TestAccAWSGuardDuty/OrganizationConfiguration/basic (46.99s) ``` * resource/aws_guardduty_organization_admin_account: Adjust for review comments Reference: hashicorp#13034 (review) Output from acceptance testing: ``` --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount (44.91s) --- PASS: TestAccAWSGuardDuty/OrganizationAdminAccount/basic (44.91s) ```
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Community Note
Closes #13005
Closes #13006
Release note for CHANGELOG:
Output from acceptance testing (from the Organizations testing account):