Skip to main content

CLI library to manage AWS ASG desired/min/max capacity by tag filters

Project description

ASG Scaling Manager

Manage AWS Auto Scaling Group capacities by tag filters with a simple, reliable CLI.

Quick Install

pip install asg-scaling-manager

Usage

# Get help
asg-sm --help

# Scale ASGs tagged with eks:cluster-name=my-cluster to 6 instances total
asg-sm --tag-value my-cluster --desired 6 --dry-run

# Apply changes with optional per-ASG max cap
asg-sm --tag-value my-cluster --desired 8 --max-size 5 --region eu-west-1

# Scale down to zero (sets min/max/desired to 0)
asg-sm --tag-value my-cluster --desired 0

Features

  • Tag-based filtering: Target ASGs by eks:cluster-name (default) or custom tags
  • Smart distribution: Evenly distributes desired capacity across matched ASGs
  • Safety first: Dry-run mode to preview changes
  • EKS optimized: Defaults to eks:cluster-name tag for easy EKS cluster management
  • Flexible caps: Optional per-ASG max size limits

Examples

# Preview scaling for production cluster
asg-sm --tag-value prod-cluster --desired 12 --dry-run

# Scale with name filter and custom tag
asg-sm --tag-key team --tag-value payments --name-contains web --desired 4

# Emergency scale down
asg-sm --tag-value staging --desired 0

Notes

  • Default tag: Uses eks:cluster-name by default (perfect for EKS clusters)
  • Desired vs max-size: --desired is total across all ASGs, --max-size is per-ASG cap
  • AWS auth: Uses --profile and/or --region for AWS credentials
  • Dry-run: Always test with --dry-run first

Alternative Installation

# Isolated install (recommended for CLIs)
pipx install asg-scaling-manager

# Development install
git clone https://github.com/grzes-94/asg-scaling-manage
cd asg-scaling-manage
pip install -e .

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

asg_scaling_manager-0.1.0.tar.gz (8.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

asg_scaling_manager-0.1.0-py3-none-any.whl (8.5 kB view details)

Uploaded Python 3

File details

Details for the file asg_scaling_manager-0.1.0.tar.gz.

File metadata

  • Download URL: asg_scaling_manager-0.1.0.tar.gz
  • Upload date:
  • Size: 8.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for asg_scaling_manager-0.1.0.tar.gz
Algorithm Hash digest
SHA256 a0488812d9bdc46f0585ce38c2f9b613b1e2b83d022d1cc2937ea7bf7052cca4
MD5 e1d4730f3b0891f1ce3bb7c433ade75e
BLAKE2b-256 749c71ded360358e067865e7ae8632f6e3b4e5e2f1ca418db073a99ab4e65926

See more details on using hashes here.

File details

Details for the file asg_scaling_manager-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for asg_scaling_manager-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d22caccc5193611a708491e6b71959f867bf46e0384b13921f9447d170bfc15d
MD5 7e93e18cd3fb3a25886ca1fa02530812
BLAKE2b-256 2a5a5fa0e91e53a3a99c6536f737595acab6dadb5f2374a6c60a96ff5d4cab04

See more details on using hashes here.

Supported by

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