Skip to main content

ecs-tool tries to eliminate common caveats for your day-to-day work with Elastic Container Service (ECS).

Project description

ECS Tool

PyPI

aws-ecs on steroids.

ecs-tool tries to eliminate common caveats for your day-to-day work with Elastic Container Service (ECS).

Dashboards with important information about your services, more intuitive CLI interface and more.

New version (0.10) is still in Beta.

Screenshots

Dashboard Cluster listing Services list

Summary of functionalities

Cluster

Service

Task

  • Run task, returns information about ran task, e.g. logs output from it (refreshed automatically)
  • Listing of all running tasks
  • Show single task, displays information about running task (refreshed automatically)
  • Show task's logs (refreshed automatically)

More detailed information about available commands below.

Installation & usage

As python package

pip install ecs-tool

ecs

# with aws-vault
aws-vault exec my-aws-profile -- ecs 

With docker

# build image
docker build -t ecs-tool

docker run -it --rm --name ecs-tool ecs-tool ecs

# with aws-vault
docker run -it --rm --env-file <(aws-vault exec my-aws-profile -- env | grep "^AWS_") --name ecs-tool ecs-tool ecs

What ecs-tool can do?

Cluster

List of available clusters

ecs cluster list

Service

List of available services

ecs service list [OPTIONS]

Options:
  -c, --cluster TEXT

Dashboard for service

ecs service dashboard [OPTIONS] SERVICE

Options:
  -c, --cluster TEXT

Task

Run task

ecs task run [OPTIONS] TASK_DEFINITION [COMMAND]...

Options:
  -c, --cluster TEXT
  --network-configuration TEXT
  --capacity-provider-strategy TEXT

TASK_DEFINITION - you can either provide full definition e.g. my-definition:123 or just name, my-definition. If no number is provided, latest version is assumed.

[COMMAND] - any command that should be executed on ECS task

Examples:

Running with Fargate

ecs task run epsy-dynks --capacity-provider-strategy '{"capacityProvider": "FARGATE"}' --network-configuration '{"awsvpcConfiguration":{"subnets":["subnet-1234567890"],"securityGroups":["sg-123456789"],"assignPublicIp":"DISABLED"}}' --  my_command subcommand --one-option --another-option="test"

List of running tasks

ecs task list [OPTIONS]

Options:
  -c, --cluster TEXT

Display information about ran task

ecs task show [OPTIONS] TASK_ID

Options:
  -c, --cluster TEXT

Display task logs

ecs task logs [OPTIONS] TASK_ID

Options:
  -c, --cluster TEXT

Can I use grep?

Yes! All commands results (but dashboards) can be filtered with grep

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ecs-tool-0.10.3.tar.gz (13.0 kB view hashes)

Uploaded Source

Built Distribution

ecs_tool-0.10.3-py3-none-any.whl (17.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page