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:
- In GitLab, on the top bar, select Menu > Projects and find your project.
- On the left sidebar, 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.
ECStriggers jobs defined in the
Jobs/Deploy/ECS.gitlab-ci.ymltemplate. 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.