-
Notifications
You must be signed in to change notification settings - Fork 0
Home
This project is part of the 42 curriculum and focuses on building a full-stack web application that allows users to play Pong in real time. The goal is to create a modern web application using microservices architecture, containerized with Docker, featuring RESTful APIs, WebSocket communication, secure authentication, and real-time multiplayer gameplay.
/ft_transcendence │ ├── /api-gateway │ ├── Dockerfile │ ├── entrypoint.sh │ ├── package.json │ └── /src │ ├── server.js │ ├── /plugins │ └── /proxy │ ├── /auth-service │ ├── Dockerfile │ ├── entrypoint.sh │ ├── package.json │ └── /src │ ├── server.js │ ├── /api │ ├── /application │ ├── /domain │ ├── /events │ └── /infrastructure │ ├── /Front │ ├── Dockerfile │ ├── index.html │ ├── package.json │ └── /src │ ├── main.ts │ ├── /components │ ├── /pages │ ├── /router │ ├── /services │ └── /utils │ ├── /game │ ├── Dockerfile │ ├── entrypoint.sh │ ├── package.json │ └── /src │ ├── Server.js │ ├── /game │ ├── /handlers │ ├── /tournament │ └── /persistence │ ├── /user-mgmt │ ├── Dockerfile │ ├── package.json │ └── /src │ ├── server.js │ ├── /api │ ├── /application │ ├── /domain │ ├── /events │ └── /infrastructure │ ├── /tournament-service │ ├── Dockerfile │ ├── package.json │ └── /src │ ├── server.js │ ├── /api │ ├── /application │ ├── /domain │ ├── /events │ └── /infrastructure │ ├── /event-bus │ ├── Dockerfile │ └── README.md │ ├── /pckg │ └── /redis │ ├── modules.js │ ├── /cache │ └── /events │ ├── docker-compose.yml ├── env_generator.sh └── Makefile
/api-gateway: This directory contains the API Gateway service that routes requests to appropriate microservices.
/auth-service: This directory contains the authentication service handling user login, registration, and JWT token management.
/Front: This directory contains the frontend SPA built with TypeScript and modern web technologies.
/game: This directory contains the server-side game engine with WebSocket support for real-time Pong gameplay.
/user-mgmt: This directory contains the user management service for profiles, avatars, and user data.
/tournament-service: This directory contains the tournament management service for organizing competitive matches.
/event-bus: This directory contains the internal event bus for inter-service communication.
/pckg: This directory contains shared packages and Redis modules used across services.
| Gateway & Routing | Authentication & Security | Game Engine | User Management | Frontend | Infrastructure |
|---|---|---|---|---|---|
API Gateway |
Auth Service |
Game Service |
User Management |
SPA Frontend |
Event Bus |
Service Proxy |
JWT Validation |
WebSocket Handler |
Profile Management |
Vue.js Components |
Redis Cache |
CORS Plugin |
2FA Implementation |
Tournament Logic |
Avatar System |
Router System |
Docker Compose |
HTTPS Config |
Password Encryption |
Real-time Communication |
User Presence |
UI Components |
Shared Packages |
- The API Gateway serves as the entry point for all client requests, routing them to appropriate microservices and handling cross-cutting concerns like CORS and SSL termination.
- The Auth Service manages user authentication, registration, JWT token generation and validation, and implements Two-Factor Authentication (2FA) for enhanced security.
- The Game Service handles the server-side Pong game logic, WebSocket connections for real-time gameplay, and tournament management for competitive matches.
- The User Management service handles user profiles, avatar uploads, user statistics, match history, and online presence tracking.
- The SPA Frontend provides a modern single-page application interface built with TypeScript, featuring responsive design and real-time updates.
- Event Bus and Redis Cache provide inter-service communication and data caching, while Docker orchestrates the entire microservices ecosystem.