Basic Recipe 🏠
The simplest way to add automated security auditing to your Python project. Perfect for getting started with zero configuration required.
Perfect For
- Simple Python projects with a single
requirements.txt
- Getting started with security automation
- Single-environment applications
- Straightforward dependency management
Project Structure
my-python-project/
├── requirements.txt # Your project dependencies
└── .github/
└── workflows/
└── security-audit.yml # Security automation workflow
Complete Workflow Configuration
Complete security-audit.yml
This is the complete workflow file that provides automated security scanning for your basic Python project.
Quick Setup Instructions
Follow these simple steps to add security auditing to your project:
Fastest Setup (Recommended)
Run this single command in your project root:
curl -sSL https://raw.githubusercontent.com/trivedi-vatsal/pysec-recipes/main/setup.py | python3
What this does:
- ✅ Creates
.github/workflows/
directory - ✅ Downloads the complete workflow file
- ✅ Sets up everything for automated security scanning
Step-by-step manual installation
If you prefer to understand each step:
-
Create the workflow directory:
-
Download the workflow file:
-
Ensure you have a requirements.txt file in your project root
-
Commit and push to trigger the workflow
Verification Steps
After setup, verify everything is working:
Test Your Setup
- Go to Actions tab in your GitHub repository
- Find the workflow "Security Audit with pip-audit"
- Click "Run workflow" → "Run workflow"
- Watch the workflow run - it should complete successfully
Expected Results: - ✅ Workflow completes without errors - ✅ Artifacts uploaded (audit results) - ✅ Issues created if vulnerabilities found
What Happens Next?
Once set up, your basic recipe will:
- 🔄 Run automatically every Monday at 8 AM UTC
- 📱 Trigger on changes to
requirements.txt
- 🚨 Create GitHub issues when vulnerabilities are found
- 📊 Upload detailed reports as workflow artifacts
- 🔍 Scan all dependencies for known security issues
Ready for More?
Once you're comfortable with the basic recipe, consider upgrading:
- Django Recipe - For Django applications
- FastAPI Recipe - For modern APIs
- Enterprise Recipe - For multiple environments
- Monorepo Recipe - For complex projects