Skip to main content

Easy to setup AWS ECS autodiscovery for Prometheus

Project description

AWS ECS autodiscovery for Prometheus

Installation:


    $ pip install discoecs

Usage examples - commandline:

Scan ECS tasks every 70 seconds, outputting Prometheus config to ecs-targets.json with 8080 as default Prometheus metrics port.

    
    $ discoecs -v -f ecs-targets.json -p 8080 -i 70

Important note: provide AWS credentials and default region in any of the boto3 library standard locations, such as ~/.aws/credentials or using environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY, AWS_DEFAULT_REGION.

Programmatic use

    >>> import boto3
    >>> import discoecs.get_cluster_tasks
    >>> ecs_client = boto3.client('ecs')
    >>> ecs_tasks = get_cluster_tasks(ecs_client)

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

discoecs-2.2.2.tar.gz (2.8 kB view details)

Uploaded Source

File details

Details for the file discoecs-2.2.2.tar.gz.

File metadata

  • Download URL: discoecs-2.2.2.tar.gz
  • Upload date:
  • Size: 2.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.6.2 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.2

File hashes

Hashes for discoecs-2.2.2.tar.gz
Algorithm Hash digest
SHA256 5fe9305e11e0786fa659459e6efd6ee50df2e7e3c4a8584fe52359645157e776
MD5 6b943a10d6e06101bd6df78ff03b1408
BLAKE2b-256 e1455fea0264d991e059463fe58103c11d420d81f227f0464251b99714875a42

See more details on using hashes here.

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