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

tests/provider: FMS Admin Account test fails in GovCloud #16106

Closed
YakDriver opened this issue Nov 10, 2020 · 2 comments · Fixed by #16041
Closed

tests/provider: FMS Admin Account test fails in GovCloud #16106

YakDriver opened this issue Nov 10, 2020 · 2 comments · Fixed by #16041
Labels
partition/aws-us-gov Pertains to the aws-us-gov partition. service/fms Issues and PRs that pertain to the fms service. service/organizations Issues and PRs that pertain to the organizations service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Milestone

Comments

@YakDriver
Copy link
Member

YakDriver commented Nov 10, 2020

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

This test fails on GovCloud:

TestAccAwsFmsAdminAccount_basic

With this error: InvalidClientTokenId: The security token included in the request is invalid. Because the test is hardcoded for us-east-1 and uses os to set environment variables, the security token is invalidated. However, the test would otherwise fail instead of skipping because the fms service is not available in GovCloud.

This test must be run in a payer account.

New or Affected Resource(s)

  • aws_fms_admin_account

Terraform Configuration Files

Example config:

resource "aws_organizations_organization" "test" {
  aws_service_access_principals = ["fms.amazonaws.com"]
  feature_set                   = "ALL"
}

resource "aws_fms_admin_account" "test" {
  account_id = aws_organizations_organization.test.master_account_id
}

Debug Output

TestAccAwsFmsAdminAccount_basic: provider_test.go:184: [{0 error configuring Terraform AWS Provider: error validating provider credentials: error calling sts:GetCallerIdentity: InvalidClientTokenId: The security token included in the request is invalid.
        	status code: 403, request id: 3e5efddb-1299-4620-bd56-769be63a98f5  []}]
--- FAIL: TestAccAwsFmsAdminAccount_basic (0.32s)

References

  • #0000
@YakDriver YakDriver added enhancement Requests to existing resources that expand the functionality or scope. partition/aws-us-gov Pertains to the aws-us-gov partition. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. and removed enhancement Requests to existing resources that expand the functionality or scope. labels Nov 10, 2020
@ghost ghost added service/fms Issues and PRs that pertain to the fms service. service/organizations Issues and PRs that pertain to the organizations service. labels Nov 10, 2020
@bflad bflad added this to the v3.15.0 milestone Nov 11, 2020
@ghost
Copy link

ghost commented Nov 12, 2020

This has been released in version 3.15.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!

@ghost
Copy link

ghost commented Dec 11, 2020

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!

@ghost ghost locked as resolved and limited conversation to collaborators Dec 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
partition/aws-us-gov Pertains to the aws-us-gov partition. service/fms Issues and PRs that pertain to the fms service. service/organizations Issues and PRs that pertain to the organizations service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
2 participants