Closed yngvark closed 4 months ago
This issue has been automatically marked as stale because it has been open 30 days with no activity. Remove stale label or comment or this issue will be closed in 10 days
This issue was automatically closed because of stale in 10 days
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.
Is your request related to a new offering from AWS?
It's not a new offering -
path
has been available for theaws_iam_policy
since 2015.Is your request related to a problem? Please describe.
Yes.
The parameters
task_exec_iam_role_path
andtasks_iam_role_path
allow me to set thepath
attribute for the IAM roles created by the service module. However, when I settask_exec_iam_role_path
, I get an IAM policy without thepath
set. This is currently not supported, as the iam policy for the service doesn't take any input for setting itspath
. Code.I would like to set the
path
attribute for the task execution IAM policy, because it enables me to set flexible IAM constraints.Motivation:
I am trying to define an IAM role with permission to the action
iam:GetPolicy
for the ECS task execution IAM policy created by the service module.I want my role to allow
iam:GetPolicy
for resources under the pathThis is not possible. Instead, I can only constrain the permission to
Describe the solution you'd like.
I want a parameter that allow me to set the
path
attribute of the resourceaws_iam_policy.task_exec
, defined here.Not sure what would be a good name.
task_exec_iam_policy_path
perhaps?Describe alternatives you've considered.
Instead of using the
task_exec_iam_role_path
, I can include a prefix in thetask_exec_iam_role_name
variable, for instanceBut there is a maximum length for IAM role names (and policy names I assume), which is why I want to use a path instead.
Additional context