CatSCAN: Terraform Cloud multi-workspace scanner
Project description
CatSCAN
Terraform Cloud multi-workspace scanner
CatSCAN is a simple, interactive CLI tool that uses the Terraform Cloud API to scan all workspaces in your organization and display a summary of resources currently running. It features an old-school ASCII aesthetic and a menu-driven interface for browsing your previous scan history.
Features
- Fetches all workspaces from Terraform Cloud
- Downloads and parses the current state for each workspace
- Counts and summarizes resource types across workspaces
- Interactive history viewer with detailed scan records
- ASCII-art banner and menu-driven UI via Rich
- Cross-platform support (Windows, macOS/Linux)
Installation
Install from PyPI:
pip install catscan-terra
Or install the latest development version directly from GitHub:
git clone https://github.com/cloudsifar/catscan.git
cd catscan
pip install --editable .
Usage
Run the scanner:
catscan
Or via Python module:
python -m catscan
Command Options
After starting, CatSCAN will prompt you to configure your Terraform Cloud organization and API token (unless set via environment variables TFC_ORG_NAME and TFC_TOKEN).
During a scan, you’ll see progress spinners and a final summary table. Options after a scan:
- H: View scan history
- R: Run another scan
- Q: Quit
Configuration
Environment Variables
For non-interactive or CI usage, export:
TFC_ORG_NAME– your Terraform Cloud organization nameTFC_TOKEN– a Terraform Cloud API token
export TFC_ORG_NAME="my-org"
export TFC_TOKEN="abcdef1234567890"
Interactive Setup
If no environment variables are found, CatSCAN will prompt you to enter and optionally persist your credentials in your shell configuration (or on Windows, the user environment).
Example Output
Found 2 workspaces
📊 Deployed Resources by Workspace (my-org)
Workspace Resources Status
-------- --------- ------
prod-app aws_instance(4) ✅ 4
dev aws_s3_bucket(2) ✅ 2
---
Contributing
I welcome suggestions and improvements! If you’re new to GitHub or pull requests don’t worry – here’s the usual workflow:
-
Fork the repository on GitHub to your own account.
-
Clone your fork locally:
git clone https://github.com/<your-username>/catscan.git cd catscan
-
Create a feature branch:
git checkout -b feature/my-feature
-
Make your changes, then commit them:
git add . git commit -m "Describe your change here"
-
Push the branch to your fork:
git push origin feature/my-feature
-
Open a Pull Request against
cloudsifar/catscanvia GitHub’s UI.- You’ll automatically be notified of comments, CI results, and merge status.
- I review and manually merge when ready.
Feel free to open issues first if you want to discuss big changes or report bugs.
Author
Simon Farrell – creator of CatSCAN and Terraform enthusiast. Follow me on LinkedIn for updates.
License
This project is licensed under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file catscan_terra-0.2.0.tar.gz.
File metadata
- Download URL: catscan_terra-0.2.0.tar.gz
- Upload date:
- Size: 13.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a65f17f7778e7213151c4a133e9a6b9fcd7200fef28db8e71f61cb15e94db556
|
|
| MD5 |
0dbd6e98757077ae22e372cf813b6910
|
|
| BLAKE2b-256 |
da4669d5503bf84974c64525a62f78c75b7307145202cb3e9903cfb5d07db492
|
File details
Details for the file catscan_terra-0.2.0-py3-none-any.whl.
File metadata
- Download URL: catscan_terra-0.2.0-py3-none-any.whl
- Upload date:
- Size: 12.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
65d73839c9453c86f2e2224dab955ecf3e01506613724e544851754c43a45bc1
|
|
| MD5 |
788faee791ae146c3ee47dd8347044fa
|
|
| BLAKE2b-256 |
894206d9eb2670671a0c2106998225fff44b0e5ccf17968f43c488b2c7400c31
|