-
Notifications
You must be signed in to change notification settings - Fork 9.5k
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
Issue importing an aws_appautoscaling_policy for a DynamoDB Table #21152
Comments
This issue is IMHO a duplicate of hashicorp/terraform-provider-aws#8306. |
This issue has been automatically migrated to hashicorp/terraform-provider-aws#8825 because it looks like an issue with that provider. If you believe this is not an issue with the provider, please reply to hashicorp/terraform-provider-aws#8825. |
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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
Hi there,
I´m using Terraform v0.11.11 with the AWS Provider to import some existing resources into the Terraform state.
Trying to import some existing DynamoDB aws_appautoscaling_policy policies, I´m getting the following errors:
terraform import aws_appautoscaling_policy.dynamodb_table_read_policy dynamodb/table/visitors/dynamodb:table:ReadCapacityUnits/DynamoDBReadCapacityUtilization:table/visitors
Error: aws_appautoscaling_policy.dynamodb_table_read_policy (import id: dynamodb/table/visitors/dynamodb:table:ReadCapacityUnits/DynamoDBReadCapacityUtilization:table/visitors): 1 error(s) occurred:
status code: 400, request id: 3ffdf95e-6ad8-11e9-ae6d-234730bc25aa
According to the Terraform official documentation
https://www.terraform.io/docs/providers/aws/r/appautoscaling_policy.html
The right way for importing this kind of resources is as follows:
Application AutoScaling Policy can be imported using the service-namespace , resource-id, scalable-dimension and policy-name separated by /.
$ terraform import aws_appautoscaling_policy.test-policy service-namespace/resource-id/scalable-dimension/policy-name
But seems like I´m having issues because in my particular case, I have some / in some of the parameters:
"name": "DynamoDBReadCapacityUtilization:table/visitors",
"resource_id": "table/visitors"
I´ve tried even Escaping those forward slashes and using double and single quotes for the parameters, with the same result.
I would really appreciate some help with this issue.
Thanks a lot !
The text was updated successfully, but these errors were encountered: