-
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
[Enhancement]: Control when aws_ecs_task_execution
is executed
#29871
Comments
Community NoteVoting for Prioritization
Volunteering to Work on This Issue
|
It feels like there is already a decent amount of control of when you do want an execution to happen using either For me, what I really want is to ensure that this does not run during |
I have created #29978 as a possible next step |
I'm try to figure out what was the original use case to create this as a A resource with a trigger of some kind just seems the most obvious. |
My less than ideal, but functional workaround for this. Create a very simple lambda that does an ECS RunTask. Use |
Having to go through Lambda is viable, but really a never-ending chore that involves introducing a ton of complexity too. Would love to have the "output of an ECS task" as a local resource, effectively. In #1703, @bflad used the resource "aws_ecs_task_definition" "example" {
# your task configuration here
}
resource "null_resource" "ecs-run-task" {
provisioner "local-exec" {
# add other args as necessary: https://docs.aws.amazon.com/cli/latest/reference/ecs/run-task.html
command = "ecs run task --task-definition ${aws_ecs_task_definition.example.arn}"
interpreter = ["aws"]
}
} This is relatively elegant, IMO. |
Description
Carrying over from here since the PR will close once the release is created #29783
Executing the
RunTask
API call on each read will inevitably be problematic. This issue is to brainstorm and chat about possible further enhancements that would give users more control over when tasks are run, or re-run.Affected Resource(s) and/or Data Source(s)
Potential Terraform Configuration
References
#29783
Would you like to implement a fix?
None
The text was updated successfully, but these errors were encountered: