-
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
[Bug]: #26878
Comments
Community NoteVoting for Prioritization
Volunteering to Work on This Issue
|
Hey @n3mawashi 👋 Thank you for taking the time to raise this! I believe the issue you're seeing here is that you're trying to pass multiple values to a single resource "aws_backup_framework" "example_framework" {
name = "example-framework"
control {
name = "BACKUP_RECOVERY_POINT_MANUAL_DELETION_DISABLED"
input_parameter {
name = "principalArnList"
value = "arn:aws:iam::*:role/SysAdminRole"
}
input_parameter {
name = "principalArnList"
value = "arn:aws:iam::*:role/OtherRole"
}
}
} |
Thanks, @justinretzolk for the quick reply. Unfortunately, that hasn't worked. still getting the same error of
|
here is the modify control code that I used
|
Hey @n3mawashi 👋 Thank you for the followup, and again, sorry that I'm not able to easily test this to have caught that error! I did a bit more digging and found that I was mistaken about the multiple I did a bit of additional testing, ran the following through Without wrapping the ARNs in quotes: input_parameter {
name = "principalArnList"
value = "[arn:aws:iam::*:role/SysAdminRole, arn:aws:iam::*:role/OtherRole]"
} Wrapping the ARNs in quotes: input_parameter {
name = "principalArnList"
value = "[\"arn:aws:iam::*:role/SysAdminRole\", \"arn:aws:iam::*:role/OtherRole\"]"
} |
Just to interject here, but I think the docs the OP linked to actually state what it's after, which is just a CSV string, so I reckon this should work: input_parameter {
name = "principalArnList"
value = "arn:aws:iam::*:role/SysAdminRole,arn:aws:iam::*:role/OtherRole"
} |
Marking this issue as stale due to inactivity. This helps our maintainers find and focus on the active issues. If this issue receives no comments in the next 30 days it will automatically be closed. Maintainers can also remove the stale label. If this issue was automatically closed and you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thank you! |
Terraform Core Version
0.1.12
AWS Provider Version
4.20.1
Affected Resource(s)
Hi - I ran into a minor bug where aws_backup_framework always expects the input parameter value to be a string. This problem is that this control requires a list or ARNs as per AWS documentation of https://docs.aws.amazon.com/config/latest/developerguide/backup-recovery-point-manual-deletion-disabled.html
To reproduce the bug
This produces an error
If I try to craft a string with escaped square bracket and commas I get the following message from the AWS API
I think the issue stems from the following:
https://github.com/hashicorp/terraform-provider-aws/blob/main/internal/service/backup/framework.go#L56
My go experience is nonexistent, but I'll try to come up with a solution.
Expected Behavior
For the ARN list to be applied as input a parameter
Actual Behavior
Errors
Relevant Error/Panic Output Snippet
No response
Terraform Configuration Files
Steps to Reproduce
Debug Output
No response
Panic Output
No response
Important Factoids
No response
References
No response
Would you like to implement a fix?
No
The text was updated successfully, but these errors were encountered: