Sarhan
07/11/2023, 12:27 AMFlow run could not be submitted to infrastructure
.
My Prefect is using ECS as infra basically following this (I’m new to using Terraform & ECS btw). We’ve been using this set up since the beginning of the year but the crashes started happening out of nowhere ~16 hours ago. Any advice welcome.Will Raphaelson
07/11/2023, 1:33 AMSarhan
07/17/2023, 8:57 AMEdward Park
07/17/2023, 4:32 PMECSTask
for the job itself in the flow code (so not the agent), but have you taken a look at the prefect-aws
docs, specifically around running an ECS task with a specific VPC and/or security group ID?
https://prefecthq.github.io/prefect-aws/ecs/#prefect_aws.ecs.ECSTask-attributes
ECSTask(
command=["echo", "hello world"],
vpc_id="vpc-01abcdf123456789a",
task_customizations=[
{
"op": "add",
"path": "/networkConfiguration/awsvpcConfiguration/securityGroups",
"value": ["sg-d72e9599956a084f5"],
},
],
)
Aifred Ong
07/18/2023, 1:01 AMSarhan
07/18/2023, 1:19 AMEdward Park
07/18/2023, 4:16 PMCraig de Gouveia
07/28/2023, 10:43 AMSarhan
07/30/2023, 2:24 PMtask_customizations
piece is set in the ECS Task block. Once that’s set, any flow run using the block as infra will use your desired security group over the default security group.
Hope you’re able to solve your issue! 🙂