Quick Start Pipeline
Here’s a minimal.gitlab-ci.yml configuration that runs Strix on every merge request:
This pipeline uses Docker-in-Docker (dind) service to run the Strix sandbox container. Ensure Docker is enabled in your GitLab Runner configuration.
Prerequisites
1
Enable Docker support
Ensure your GitLab Runner has Docker-in-Docker (dind) or Docker socket access enabled.
2
Configure CI/CD variables
Add these variables in Settings → CI/CD → Variables:
STRIX_LLM- Your LLM provider and model (e.g.,openai/gpt-5)LLM_API_KEY- Your LLM API key (mark as masked)
LLM_API_BASE- Custom API endpointPERPLEXITY_API_KEY- For enhanced search capabilities
3
Get API credentials
Obtain an API key from your chosen provider:
- OpenAI for GPT models
- Anthropic for Claude models
- Strix Router for multi-provider access
Complete Pipeline Examples
Merge Request Scanning
Scan code changes on every merge request with artifact storage:Scheduled Comprehensive Scans
Run deeper security assessments on a schedule:Multi-Stage Pipeline
Integrate Strix into a multi-stage deployment pipeline:Multi-Target Testing
Test both source code and deployed staging environment:Authenticated Testing
Perform grey-box testing with credentials:Runner Configuration
Docker-in-Docker (dind)
The recommended approach uses Docker-in-Docker:Docker Socket Binding
Alternatively, bind the Docker socket (requires privileged runner):Pipeline Configuration Options
Timeout Settings
Set appropriate timeouts based on your scan depth:- Quick scans: 30 minutes
- Standard scans: 1 hour
- Comprehensive scans: 2 hours
Environment Variables
Handling Results
Artifacts Configuration
Save scan results as pipeline artifacts:Conditional Failure
Control whether vulnerabilities block the pipeline:Optimization Tips
1
Use quick scan mode for MRs
Enable
--scan-mode quick for faster merge request feedback:2
Adjust reasoning effort
Set
STRIX_REASONING_EFFORT="medium" for faster CI/CD runs:3
Cache Docker images
Enable Docker layer caching to speed up image pulls:
4
Separate quick and deep scans
Use quick scans for merge requests and scheduled jobs for comprehensive testing:
Troubleshooting
Docker Permission Issues
If you encounter Docker permission errors:Runner Compatibility
Ensure your GitLab Runner supports Docker:Memory Limits
For large scans, increase memory limits:Installation Failures
If the installation script fails:Security Best Practices
- Protect variables - Mark API keys as masked and protected
- Limit scope - Only scan authorized targets
- Use protected branches - Run comprehensive scans only on protected branches
- Review findings - Set up notifications for security findings
- Rotate credentials - Regularly rotate API keys
Next Steps
- Review GitHub Actions integration for comparison
- Learn about Docker configuration for custom sandbox setups
- Explore CLI options for advanced configuration