Saltar al contenido

In an ECS Task Container deployment order

0

Can I use the CDK in Typescript to set or manipulate the container deployment order? I have 3 containers in a task, A, B, C. However, C should only be deployed when A and B are in the last status "Running". This is because container C has dependencies on A and B.

preguntada hace 2 años416 visualizaciones

1 Respuesta
0

Hello.

By using "dependsOn" in the task definition, it is possible to run it after the container has started.
https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_ecs.ContainerDefinition.html#containerdependencies

I think it is possible with CDK by using "containerDependencies" in the container definition.
https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_ecs.ContainerDependency.html

EXPERTO

respondido hace 2 años

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.