I am able to create and deploy a target group with "replicas: 3" using "docker compose up" from a YAML file, and I am able to make the TargetGroup sticky using the console using the recipe found here but have not been able to find a way to specify in the YAML that the group should be created sticky. Based on fragments found on line, I have tried adding "x-aws-target-group-sticky: true" in the ports section for the service, and adding a "targetgroupattributes" section with Key: stickiness.enabled, Value: true. The former seems to have no effect, the latter offended docker compose so much that it refused to speak to me again until I rebooted my (Windows) machine. Is there supposed to be a way to set this up?
Asked
Active
Viewed 32 times
0
-
1I suggest reading the documentation for AWS support in docker-compose. https://docs.docker.com/cloud/ecs-integration/ especially the section "Tuning the CloudFormation template" – Mark B Sep 27 '22 at 14:51
-
Thanks, after a bit of head scratching (like figuring out what "an overlay" was), that was what I needed! It is rather nasty that, if you accidentally indent the x-aws-cloudformation overlay by two spaces, docker compose issues no output, and subsequently refuses to do ANYTHING more until you reboot. – Morten Kromberg Sep 27 '22 at 18:00
-
And after a bit more debugging, it is clear to me that I was mis-diagnosing the docker compose failures. They were not linked to anything specific that I did to the YML file, they were just ocurring at random. – Morten Kromberg Sep 27 '22 at 20:41