Continuous Delivery
We use GitHub Actions for powering our automated delivery pipelines. Evolve includes several pipeline configurations that allow you to automatically deliver the platform from day one.
Overview
Our continuous delivery setup leverages GitHub Actions to automate various aspects of the build, test, and deployment process across multiple cloud platforms (AWS, GCP, and Azure).
Key Components
-
Monorepo Structure: Our codebase is organized as a monorepo, which allows for easier management of dependencies and shared code across different parts of the platform.
-
pnpm and Turborepo: We use pnpm as our package manager and Turborepo for optimizing builds in our monorepo structure.
-
MACH Composer: We utilize MACH composer for managing and deploying our microservices architecture.
-
Multi-Cloud Support: Our pipelines are designed to support deployments to AWS, GCP, and Azure, as well as specialized platforms like Vercel for frontend hosting.
Main Workflows
CI/CD Pipeline
Our main CI/CD pipeline (ci-cd.yaml) includes the following key steps:
- Validation: Checks for changes and validates the codebase.
- Testing: Runs unit tests and reports coverage.
- MACH Composer Validation: Validates configurations for different cloud environments.
- Storybook Testing: Runs tests for our Storybook components.
- Service-Specific Builds: Triggers builds for individual services based on changes.
- Test environment deployment: deployment of MACH composer configurations for AWS, Azure and GCP.
Preview Environments
We use preview environments (preview-env-create.yaml) to deploy changes for
pull requests, allowing for easier review and testing of changes before they're
merged.
Storybook deployment
A separate workflow (deploy-storybook.yaml) handles the deployment of
Storybook to ensure the component library is always up-to-date.
Optimization Strategies
- Caching: We implement caching for pnpm, Turborepo, and Terraform plugins to speed up builds.
- Conditional Job Execution: Jobs are only run when relevant files have changed, reducing unnecessary builds.
- Parallel Execution: Where possible, jobs are run in parallel to minimize overall pipeline duration.
Security Considerations
- CODEOWNERS: We use a CODEOWNERS file to ensure the right teams review changes to critical parts of the codebase.
- Secrets Management: Sensitive information is stored as GitHub Secrets and accessed securely within workflows.
- Pull Request Validation: Automated checks (
validate-pull-request.yaml) ensure pull requests meet standards before merging.
Continuous Improvement
Our continuous delivery setup is constantly evolving. We regularly review and optimize our workflows to improve efficiency, reduce build times, and enhance the developer experience.
For more detailed information on optimizing deployments as your project grows, please refer to our Optimizing Deployments guide.