Some checks failed
Lint, Build, and Docker / Check Code Formatting (push) Failing after 42s
Lint, Build, and Docker / Run Clippy Linter (push) Failing after 2s
Lint, Build, and Docker / Build Rust Binary (push) Has been skipped
Lint, Build, and Docker / Build Docker Image (push) Has been skipped
Lint, Build, and Docker / CI Summary (push) Failing after 1s
- Add cargo fmt --check to enforce code formatting
- Add pull_request trigger for PR validation
- Split workflow into parallel jobs (format, clippy, build, docker)
- Integrate Docker Buildx with DinD service
- Add BuildKit caching for faster builds
- Add local test script (scripts/test-ci-locally.sh)
- Add comprehensive documentation
All local CI checks pass ✅
1.6 KiB
1.6 KiB
CI/CD Quick Reference
Fast reference for the Forgejo CI/CD pipeline.
Trigger CI
# Push to main or develop
git push origin main
git push origin develop
# Create/update pull request
# Automatically triggers CI
Local Pre-Commit Check
# Run all CI checks locally
./scripts/test-ci-locally.sh
# Individual checks
cd backend
cargo fmt --all -- --check # Format check
cargo clippy --all-targets --all-features -- -D warnings # Lint
cargo build --release # Build
Fix Common Issues
Format Fail
cd backend
cargo fmt --all
git commit -am "style: auto-format"
Clippy Fail
cd backend
cargo clippy --all-targets --all-features -- -D warnings
# Fix issues, then commit
CI Jobs
| Job | Time | Purpose |
|---|---|---|
| format | ~10s | Check code formatting |
| clippy | ~30s | Run linter |
| build | ~60s | Build binary |
| docker-build | ~40s | Build Docker image |
Total: ~2.5 min (parallel execution)
Monitor CI
URL: http://gitea.soliverez.com.ar/alvaro/normogen/actions
Docker Build Details
- Builder: Docker Buildx v0.29.1
- Service: DinD (docker:dind)
- Socket: TCP (localhost:2375)
- Cache: BuildKit local cache
- Images:
normogen-backend:latestnormogen-backend:{sha}
Workflow File
.forgejo/workflows/lint-and-build.yml