Gitlab runner on fargate | docker in docker issues

I am referring to the link
for auto scaling gitlab ci on fargate, but it would be really appreciated if I can get help over the following topics:

  1. Fargate doesn’t support docker in docker so I cannot use custom images as a part of the pipeline, I have a use case where I need to use platform specific docker images for running various applications, say for eg:- I need to build all my python projects on a specific python image and java on a separate java image.

Is there any way this can be achieved, coz in the documentation we just need to specify the task definition there is no way we can choose a specific .toml file based on some condition.

  1. Any recommendations for EC2 instance type will be appreciated

Many thanks in advance!