AWS CLI Top 8 ECS Command

AWS Jul 12, 2023

Here is my top 10 command used with aws ecs

First of all, you NEED tab completion.

No one can remember that long stuff and type it correctly all the time.

Go get it here.

1. See the cluster

aws ecs list-clusters

2. What’s running?

aws ecs describe-tasks --cluster <cluster_name> --tasks <hash>

3. Oh, How do I Get the Task hash?

aws ecs list-tasks --cluster <cluster_name>

4. What’s the services we have?

aws ecs list-services --cluster <cluster_name>

5. What’s inside that services

aws ecs describe-services \
--cluster <cluster_name> \
--services <service_name>

6. See my Task definition

aws ecs list-task-definitions

7. What’s in that Task Definition?

aws ecs describe-task-definition --task-definition <task_def_name>

Note: no need to be specific with version like my-task-def:25 can be task definition ‘family’ name i.e. my-task-def

8. Show me how to input that command

aws ecs some-command help

See you then !

Tags

TeamCMD

We are CODEMONDAY team and provide a variety of content about Business , technology, and Programming. Let's enjoy it with us.