CI/CD Integration
Add Treeship attestations to your CI/CD pipelines to create verifiable records of builds, tests, and deployments.Why CI/CD Attestation?
| Benefit | Description |
|---|---|
| Deployment receipts | Cryptographic proof of what was deployed |
| Audit trail | Complete history of all pipeline runs |
| Accountability | Know which agent/process made changes |
| Compliance | Meet audit requirements with verifiable records |
GitHub Actions
Basic Deployment Attestation
Test Results Attestation
Security Scan Attestation
GitLab CI
Using the CLI
Install the Treeship CLI for simpler attestations:Python SDK
For complex pipelines, use the Python SDK:Verification in Pipelines
Verify previous attestations before deploying:Reusable Workflow
Create a reusable attestation workflow:.github/workflows/attest.yml:
Best Practices
1. Unique Agent per Stage
Use different agent slugs for different pipeline stages:test-runner- for test jobssecurity-scanner- for security scansstaging-deploy- for staging deploymentsproduction-deploy- for production deployments
2. Include Commit Hash
Always include the git commit in your attestation:3. Attest Failures Too
Record failed runs for complete audit trail:4. Secure Your API Key
Store TREESHIP_API_KEY as a repository secret, never in code.Viewing CI/CD Attestations
All pipeline attestations are visible at:https://treeship.dev/verify/github-actionshttps://treeship.dev/verify/production-deployhttps://treeship.dev/verify/security-scanner
Next Steps
- Cursor MCP Setup - Add Treeship to your IDE
- Automatic Attestation - Attestation patterns
- API Reference - Full API documentation