This is a template repository with pre-configured secret scanning using Gitleaks.
- ✅ Gitleaks GitHub Action - Automatic secret scanning on every push and PR
- ✅ Custom rules - Detects GoCardless, OpenRouter, OpenAI, PostgreSQL, and 140+ other secrets
- ✅ False positive handling - Pre-configured ignore patterns
- ✅ Zero maintenance - Runs automatically forever
- Click "Use this template" button above
- Create your new repository
- Gitleaks is automatically included ✅
# Copy files to your existing repo
cd /path/to/your-repo
curl -O https://raw.githubusercontent.com/fhalamzie/repo-template/main/.github/workflows/gitleaks.yml
curl -O https://raw.githubusercontent.com/fhalamzie/repo-template/main/.gitleaksignore
curl -O https://raw.githubusercontent.com/fhalamzie/repo-template/main/.gitleaks.toml
# Create workflows directory if needed
mkdir -p .github/workflows
mv gitleaks.yml .github/workflows/
# Commit and push
git add .github/workflows/gitleaks.yml .gitleaksignore .gitleaks.toml
git commit -m "feat: add Gitleaks secret scanning"
git pushEvery push and pull request is automatically scanned for:
- API keys (OpenAI, OpenRouter, AWS, Azure, etc.)
- Database credentials
- Private keys (SSH, RSA, etc.)
- OAuth tokens
- And 140+ more secret patterns
- ❌ GitHub Action fails
- 📧 Email notification sent
- 💬 Comment posted on PR
- 📊 Detailed report generated
- 🚫 Prevents merging until fixed
Edit .gitleaksignore:
path/to/false/positive.py
Edit .gitleaks.toml:
[[rules]]
id = "my-custom-secret"
description = "My Custom Secret Pattern"
regex = '''my-secret-[0-9]+'''For detailed setup and troubleshooting, see the Gitleaks documentation.
Template created for automated security across all repositories 🛡️