Deploy-ECS.gitlab-ci.yml
template issue
I’m on gitlab.com and tried deploying to AWS ECS using the instructions for including the Deploy-ECS.gitlab-ci.yml
template found here.
It is failing with the following error:
Authenticating with credentials from job payload (GitLab Registry)
$ ecs update-task-definition
An error occurred (InvalidParameterException) when calling the UpdateService operation: Task definition does not support launch_type FARGATE.
Running after_script
00:01
Uploading artifacts for failed job
00:02
ERROR: Job failed: exit code 1
I believe I may have found a solution here where Ryangr() advises that the --requires-compatibilities "FARGATE"
flag needs to be on added to the aws ecs register-task-definition
command. This is supported by the AWS documentation
* In the AWS Management Console, for the Requires Compatibilities field, specify FARGATE.
* In the AWS CLI, specify the --requires-compatibilities option.
* In the Amazon ECS API, specify the requiresCompatibilities flag.
The issue is I don’t know how to get that added into the Deploy-ECS.gitlab-ci.yml
template.