Never commit credentials to this repository.
The rst2kb tool requires an Open WebUI API key to upload files. This key must be provided via environment variables:
export OPENWEBUI_API_KEY="your-api-key-here"OPENWEBUI_API_KEY- Your Open WebUI API bearer token (required for upload mode)OPENWEBUI_URL- Open WebUI base URL (optional, defaults tohttp://localhost:3000)
- Use environment variables - Never hardcode API keys in scripts or configuration files
- Use
.envfiles locally - Add.envto.gitignoreand use a.env.exampleas a template - Rotate keys regularly - If you suspect a key has been exposed, rotate it immediately
- Use least privilege - Create API keys with minimal required permissions
Consider installing a pre-commit hook to prevent accidental commits of secrets:
pip install pre-commit
cat > .pre-commit-config.yaml << 'EOF'
repos:
- repo: https://github.com/Yelp/detect-secrets
rev: v1.4.0
hooks:
- id: detect-secrets
EOF
pre-commit installIf you discover a security vulnerability, please open an issue (if public) or contact the maintainers directly (if sensitive).