MachaOn-C1 Project
The MachaOn-C1 Project is a modular and scalable solution designed to bridge frontend and backend services into a cohesive application. By leveraging reusable libraries, robust integrations, and modern development practices, MachaOn-C1 delivers a platform capable of meeting complex business needs with ease and flexibility.
Project Structure
The MachaOn-C1 project is divided into two primary components:
-
Frontend:
- Built on the foundations of machaon-c1 Frontend, the MachaOn-C1 Frontend utilizes Mach-B TypeScript libraries to simplify UI development while allowing customization through adapters.
- Fully deployed as a static web application on Amazon S3, it offers a responsive and user-focused interface.
-
Backend:
- The MachaOn-C1 Backend is built with FastAPI, providing a robust, modern API service that adheres to Clean Architecture principles.
- Enables secure interaction with external systems (like Commercetools) via adapters, while JWT-based authentication ensures secure access to sensitive endpoints.
- Designed for scalability and extensibility, the backend integrates seamlessly with the frontend.
How It All Fits Together
The frontend and backend work together to form the complete MachaOn-C1 application, enabling everything from user authentication to order management. This modular design ensures maintainability and allows for independent updates without disrupting the overall system.
- The Frontend securely interacts with backend endpoints for user login, registration, product retrieval, and order submission.
- The Backend serves validated data to the frontend while safeguarding operations with JWT authorization and leveraging the power of third-party systems like Commercetools.
References to Detailed Sub-Projects
-
- Learn more about how MachaOn-C1 builds its frontend using Mach-B TypeScript libraries and custom adapters for specific UI requirements.
-
- Explore the architecture, key features, and components of the FastAPI-based backend, with a focus on JWT-based security, modular endpoints, and external integrations.
Key Features of MachaOn-C1
-
Modularity:
- Reusable libraries for both front and backend services ensure consistency and reduce development overhead.
-
Security:
- Fully supports JWT-based authorization for secure data exchanges.
- Protected backend endpoints for sensitive operations (e.g., order creation) ensure compliance with modern security standards.
-
Cohesive Integration:
- The frontend seamlessly leverages backend services through RESTful APIs.
- Backend integrations with Commercetools ensure robust data handling for products, users, and orders.
-
Cloud-Native Deployment:
- Frontend: Deployed on Amazon S3, enabling global, scalable, and cost-effective UI access.
- Backend: Easily deployable to AWS Lambda, EC2, or any other scalable hosting solution.
-
Customization:
- The project's layered architecture allows easy customization of both frontend (via adapters) and backend (via interactors and adapters).
Getting Started
1. Clone the Repository
git svn clone https://svn.code.sf.net/p/machc/svn/trunk/machaon/containers/machaon-c1
cd machaon-c1
2. Install Docker
See: Docker
3. Follows the instructions in the subprojects
Docker Image Compose
Docker Compose is used to build and run the MachaOn-C1 project in a containerized environment. Using a single docker-compose.yml
file, the entire application stack—including the frontend, backend, and database dependencies—can be managed and orchestrated effortlessly.
Steps to Run:
Start the Containers
Run the following command to build and start all services defined in the docker-compose.yml
file:
docker-compose up
Access the Application
Once the containers are up and running, access the application using the URLs or ports specified in the Compose file (e.g., http://localhost:8080
for the frontend or http://localhost:8000
for the backend).
When you're done, stop the containers with:
docker-compose down