Use Auto DevOps to deploy to Amazon ECS
Introduced in GitLab 13.0.
You can choose to target AWS ECS as a deployment platform instead of using Kubernetes.
To get started on Auto DevOps to AWS ECS, you must add a specific CI/CD variable. To do so, follow these steps:
- On the left sidebar, select Search or go to and find your project.
- Select Settings > CI/CD.
- Expand Auto DevOps.
- Specify which AWS platform to target during the Auto DevOps deployment
by adding the
AUTO_DEVOPS_PLATFORM_TARGETvariable with one of the following values:
FARGATEif the service you're targeting must be of launch type FARGATE.
ECSif you're not enforcing any launch type check when deploying to ECS.
When you trigger a pipeline, if you have Auto DevOps enabled and if you have correctly entered AWS credentials as variables, your application is deployed to AWS ECS.
If you have both a valid
AUTO_DEVOPS_PLATFORM_TARGET variable and a Kubernetes cluster tied to your project,
only the deployment to Kubernetes runs.
AUTO_DEVOPS_PLATFORM_TARGET variable to
ECS triggers jobs
defined in the
However, it's not recommended to include
it on its own. This template is designed to be used with Auto DevOps only. It may change
unexpectedly causing your pipeline to fail if included on its own. Also, the job
names within this template may also change. Do not override these jobs' names in your
own pipeline, as the override stops working when the name changes.