This directory contains C4 model files for visualizing the OpenCloud architecture using the LikeC4 modeling language.
The C4 model provides a way to visualize software architecture at different levels of abstraction:
- Context: Shows how the system interacts with users and other systems
- Containers: Shows the high-level technology choices and how containers communicate
- Components: Shows how a container is made up of components
- Code: Shows how a component is implemented (optional)
Our LikeC4 implementation uses a text-based DSL (Domain Specific Language) to define these models, making them version-control friendly and easier to maintain than diagrams.
opencloud.c4: Main system model defining components, relationships and viewsspec.c4: Specification of styles and notationsdeployment.c4: Deployment model showing Kubernetes resources and topology
The rendered diagrams are deployed at:
These are automatically generated during the build process and updated with each deployment.
The project has a built-in script to render the C4 models:
# Install dependencies
pnpm install
# Build the LikeC4 diagrams
pnpm build-likec4This will generate the diagrams in the /static/likec4/ directory which will be included in the built documentation site.
For quick edits and visualization:
- Visit https://likec4.dev/playground/
- Copy and paste the contents of the
.c4files - Visualize in real-time and export diagrams as needed
When modifying the C4 models:
- Make changes to the relevant
.c4files - Run
pnpm build-likec4to regenerate the diagrams - Preview the changes in the documentation site with
pnpm start - Commit both the
.c4source files and the generated diagrams