This document explains the Continuous Integration and Deployment (CI/CD) pipelines for the Web3 Student Lab project. These pipelines ensure that all code contributions are verified for quality, security, and correctness before being merged.
We use GitHub Actions for our CI/CD workflows. The pipeline is triggered automatically on every
push to the main branch and for every pull_request targeting the main branch.
The CI pipeline is divided into three parallel jobs: Backend, Frontend, and Contracts.
When a contributor pushes code or opens a PR, GitHub Actions initiates the workflow defined in
.github/workflows/ci.yml.
For each service (Backend, Frontend, and Contracts), the pipeline performs a build verification step:
- Backend: Runs
npm run buildto ensure TypeScript compilation passes. - Frontend: Runs
npm run build(Next.js build) to verify the application can be bundled successfully. - Contracts: Runs
cargo buildfor Soroban smart contracts.
The pipeline runs the following automated checks to maintain code quality:
- Unit Tests: Executes
npm testusing Jest. This verifies the core business logic, API endpoints, and utility functions. - Service Verification: Ensures that the backend can connect to a mock database and that the API schema is consistent.
- Linting: Runs
npm run lintusing ESLint to enforce consistent coding styles and catch common errors. - Static Analysis: Next.js build verification includes a type-checking phase for TypeScript.
- Compilation: Verifies that the Rust smart contracts compile successfully for the
wasm32-unknown-unknowntarget.
Note: Deployment pipelines are currently under development.
The planned flow for CD is as follows:
- Staging: Merges to
maintrigger an automatic deployment to a staging environment (e.g., Render or Vercel). - Production: Tagged releases are deployed to the production environment after final manual verification.
Last Updated: 2026-03-24