gpt4 book ai didi

docker - AWS Elastic Container Service CI模板问题

转载 作者:行者123 更新时间:2023-12-02 19:18:11 25 4
gpt4 key购买 nike

我在gitlab.com上,并尝试按照包含here找到的Deploy-ECS.gitlab-ci.yml模板的说明,部署到Fargate AWS ECS容器。

失败并显示以下错误:

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

我相信我可能已经找到了 here解决方案,其中Ryangr()建议将 --requires-compatibilities "FARGATE"标志添加到 aws ecs register-task-definition命令中。这是 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.

我想知道是否有一种方法可以覆盖Deploy-ECS.gitlab-ci.yml模板并添加它,或者我是否只需要通过GitLab提交问题单。

最佳答案

使用GitLab 13.2 (July 2020)再次检查:

Bring Fargate support for ECS to Auto DevOps and ECS template


We want to make AWS deployments easier.
In order to do so, we recently delivered a CI/CD template that deploys to AWS ECS:EC2 targets and even connected it to Auto DevOps.

Scaling container instances in EC2 is a challenge, so many users choose to use AWS Fargate instead of EC2 instances.
In this release we added Fargate support to the template, which continues to work with Auto DevOps as well, so more users can benefit from it.


这链接到 issue 218841,其中包括提案:

Use the gitlab-ci.yml template for deploying to AWS Fargate.

We will enforce the presence of --requires-compatibilities argument from the launch type - this will only be passed in case Fargate is selected.
If ECS is selected as the launch type this is ignored.


正如 David Specht中的 the comments所指出的那样,已使用 issue 218798中的 cloud-deploy MR (Merge Request) 16commit 2c3d198将其关闭。

关于docker - AWS Elastic Container Service CI模板问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/61994312/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com