I wanted to build a small config-driven automation tool inspired by infrastructure and code-quality workflows. This project reads a YAML configuration file, prepares scan jobs, and runs my Git secret scanner automatically.
- Loads scan jobs from a YAML config file
- Iterates through configured instances
- Runs a secret scanning tool with parameters from config
- Saves scan results to the specified output file
src/main.py— CLI entry pointsrc/config_loader.py— YAML config loadingsrc/runner.py— scan job execution logicconfig.yaml— example configuration file
instances:
- name: local-secret-scan
repo_path: /Users/kveit/git-secret-clean
check: secret_scan
output_file: report.json
commits: 5Create a .env file in the project root:
SECRET_SCANNER_PATH=/absolute/path/to/git-secret-clean/main.pypython3 src/main.py --config config.yaml- Python 3.10+
- PyYAML
- python-dotenv (if .env loading is used)
Right now the project supports one check type:
- secret_scan
Future improvements may include:
- support for multiple check types
- better validation of config structure
- richer status reporting