amazon-ecs-cli | The Amazon ECS CLI enables users to run their applications on ECS/Fargate using the Docker Compose f | AWS library
kandi X-RAY | amazon-ecs-cli Summary
kandi X-RAY | amazon-ecs-cli Summary
The Amazon ECS Command Line Interface (CLI) is a command line tool for Amazon Elastic Container Service (Amazon ECS) that provides high-level commands to simplify creating, updating, and monitoring clusters and tasks from a local development environment. The Amazon ECS CLI supports Docker Compose, a popular open-source tool for defining and running multi-container applications. Use the CLI as part of your everyday development and testing cycle as an alternative to the AWS Management Console or the AWS CLI. For more information about Amazon ECS, see the Amazon ECS Developer Guide. The AWS Command Line Interface (AWS CLI) is a unified client for AWS services that provides commands for all public API operations. These commands are lower level than those provided by the Amazon ECS CLI. For more information about supported services and to download the AWS CLI, see the AWS Command Line Interface product detail page. If you think you’ve found a potential security issue, please do not post it in the Issues. Instead, please follow the instructions here or email AWS security directly at aws-security@amazon.com.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of amazon-ecs-cli
amazon-ecs-cli Key Features
amazon-ecs-cli Examples and Code Snippets
Community Discussions
Trending Discussions on amazon-ecs-cli
QUESTION
I use an open-source server application running on Docker Compose. It has a few services, including PostgreSQL DB and Redis.
How can I best deploy this application to AWS in full IaC with Terraform?
ecs-cli
ecs-cli
now supports sending docker compose
configs in Amazon ECS.
However, I do not think it could be integrated with the Terraform workflow (which is maybe not a big fuss). What I know for sure is that ecs-cli
is not supported in CloudFormation, as per this issue, still open at this time. So I assume it cannot easily be added to Terraform either.
- Take your
docker-compose.yml
file, translate it tokubectl
YAML. - (Prepare to doing so every time the package upgrades).
- Deploy using Terraform's + EKS APIs (minimal example).
But that is not fully IaC yet. And you have to retranslate your config each time the docker-compose changes in the source repository. And it sounds like a lot of work.
3. Using a Helm chart- Write a Helm chart for the application.
- Run Terraform to start a cluster.
- Still run Terraform with a
helm
provider to install the application with Helm on the cluster.
I read Kompose can automagically translate a Docker Compose configuration to a k8s configuration, but they don't appear to be ported on AWS, not to talk about Terraform.
5. [Not OK] The dirty AMI solution- Build a custom EC2 AMI with Packer.
- Using Terraform, set up the DB, Redis and all permissions / network / etc.
- Start an EC2 instance with the custom AMI.
- The AMI contains (customized) application code, especially the
docker-compose.yml
. And the Docker images. - The AMI starts a Docker Compose
systemctl
service.
That would kind of hurt: long builds, difficult monitoring, no scaling.
Side notes- I mentioned I need full IaC. What I mean by it is:
- The written config (and it only) on
master
tells you what is deployed. - The deploy will complete without my team having to run any other command. It basically works either on CI/CD or on single-push'n'go.
- Monitoring and alerting are easily configured in the IaC.
- The written config (and it only) on
- I wish to replace some services with AWS components (namely, the PostgreSQL service by an RDS, and the Redis service with an ElastiCache).
- The application happens to be Apache Superset. However I am also wondering what is considered the best general approach to this Docker Compose problem.
ANSWER
Answered 2020-Apr-20 at 14:22Who knows, ecs-cli-v2
might be better integrated with CloudFormation and/or Terraform.
As mentioned in the question. Probably the best solution, albeit requiring a (little) effort to parametrize Helm.
See also: Getting started with Helm.
3. Docker Swarm + CloudFormation + TerraformDocker Swarm now accepts inputs from a docker-compose.yml
file. The template can be found and configured here. Once configured, it may be integrated to a Terraform infrastructure.
This (3-year old) tutorial explains how to use Docker Swarm mode on AWS.
To launch the container, if necessary (not fully investigated, feedback is welcome), you could use Terraform's local-exec
. This way you can SSH into the master node and run docker stack deploy
and other similar commands, while still having all written down in IaC style.
QUESTION
When using a custom IAM Role as an ECS Task Definition'scustom execution role, our resulting Service wil fail to startup on our ECS instance due to an inability to initialize the CloudWatch logging driver. Specifically, we see the following errors from ECS agent in CloudWatch:
...ANSWER
Answered 2019-Oct-25 at 05:30if you have failure in this case, check 2 options.
ECS execution role policy
's permission. it should containslogs:CreateLogStream
andlogs:PutLogEvents
. like :
QUESTION
I want to replicate the infrastructure from one region(us-east-1) to another(us-east-2). so,I have generated a cloudfromation template of an existing infrastructure with the help of cloudformer tool.
...ANSWER
Answered 2018-Nov-19 at 05:41After a lot of debugging, when I started launching the things manually, I found the same error and I got to know that c3.large is causing the error. When I launch the template with c4.large it successfully launched the template from us-east-1 to us-east-2.
QUESTION
I am running amazon AWS ECS container which creates one single instance of EC2. I made sure that it is 1 instance when I created ECS.
My issue is that I have another instance running in EC2 and amazon has sent me an email that I am using double of the free quota and will be charged.
But I am not sure why this second EC2 instance is coming from.
I have terminated it many times but it is recreated. When I terminate it, this is the prompt i receive which advises me that it is created from EBS but there is no app in EBS
...ANSWER
Answered 2017-Dec-18 at 13:54check if you have any Auto Scaling Groups
that you do not recognize. It is most probably being created because of it. If not, change your account password and deactivate/delete your existing AccessKeys.
QUESTION
I am trying to deploy a Docker container into EC2 Container Services with GitLab pipelines. I have created the Cluster in AWS already and 2 instances are also running. The problem is that once the command
...ANSWER
Answered 2017-Aug-30 at 18:21The issue is clear. Your compose file is for build and doesn't have image
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install amazon-ecs-cli
Linux (amd64): https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-linux-amd64-latest https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-linux-amd64-latest.md5
Linux (arm64): https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-linux-arm64-latest https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-linux-arm64-latest.md5
Macintosh: https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-darwin-amd64-latest https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-darwin-amd64-latest.md5
Windows: https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-windows-amd64-latest.exe https://amazon-ecs-cli.s3.cn-north-1.amazonaws.com.cn/ecs-cli-windows-amd64-latest.md5
Using the URLs above, replace latest with the desired tag, for example v1.0.0. After downloading, remember to rename the binary file to ecs-cli. NOTE: Windows is only supported starting with version v1.0.0. NOTE: ARM64 is only supported starting with version v1.20.0.
Linux (amd64): https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-linux-amd64-v1.0.0 https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-linux-amd64-v1.0.0.md5
Linux (arm64): https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-linux-arm64-v1.20.0 https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-linux-arm64-v1.20.0.md5
Macintosh: https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-darwin-amd64-v1.0.0 https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-darwin-amd64-v1.0.0.md5
Windows: https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-windows-amd64-v1.0.0.exe https://amazon-ecs-cli.s3.amazonaws.com/ecs-cli-windows-amd64-v1.0.0.md5
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page