# alucrece/deploiement_continu architecture

> Architecture diagram of the GitHub repository alucrece/deploiement_continu, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-10-09). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/alucrece/deploiement_continu
- Repository: https://github.com/alucrece/deploiement_continu

## Overview

##### Project type and purpose
- This is a full-stack web application with a React frontend (“my-app”) and a Python backend (“server”).
- It includes database schema migrations (SQLFiles), local orchestration (docker-compose), and a CI/CD pipeline (GitHub Actions, Codecov, GitHub Pages).
- The README focuses on the React side (Create React App), test coverage, and automatic GitHub Pages deployment.

##### File structure
- Top level:
- `.github/` – CI workflows.
- `docker-compose.yml` – local dev orchestration.
- `SQLFiles/` – migration scripts for the database.
- `my-app/` – React client, tests (Jest + React Testing Library + Cypress), build config, Dockerfile.
- `server/` – Python service (`server.py`), Dockerfile, requirements, test coverage report, Vercel config.
- Patterns:
- Two distinct microservices (frontend, backend).
- SQL migrations as a separate component.
- CI/CD workflows trigger on push and PR.
- Containerization for reproducible dev and production.

##### README for additional insights
- Describes:
- React scripts (start, test, build, eject).
- Test coverage of 100%.
- GitHub Actions steps: install, test, coverage, Codecov upload, build, deploy front-end.
- Mentions E2E tests via Cypress (optional).

##### Elements
- Blue for user-facing components (Browser, SPA)
- Green for compute services (API, CI runner)
- Orange for data stores (DB, migrations)
- Grey for external services (GitHub Actions, Codecov, GitHub Pages)

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% User Layer
    A["User (Browser)"]:::frontend

    %% Local Development Environment
    subgraph "Local Development"
        B["React SPA (my-app)"]:::frontend
        C["Python API (server)"]:::backend
        D["PostgreSQL Database"]:::database
        E["SQL Migrations"]:::database
        F["Docker Compose"]:::infra
    end

    %% CI/CD Pipeline
    subgraph "CI/CD Pipeline (GitHub Actions)"
        G["CI Runner"]:::ci
        H["Codecov"]:::external
        I["GitHub Pages"]:::external
        J["Vercel (Backend)"]:::external
    end

    %% Connections - Local Dev
    A -->|"HTTP 3000"| B
    B -->|"REST 5000"| C
    C -->|"SQL Queries"| D
    E -->|"migrations"| D
    F -->|"orchestrates"| B
    F -->|"orchestrates"| C
    F -->|"orchestrates"| D

    %% Connections - CI/CD
    A -.->|push| G
    B -->|"unit & E2E tests"| G
    C -->|"unit tests"| G
    G -->|"upload coverage"| H
    G -->|"build & deploy front-end"| I
    G -->|"deploy API"| J

    %% Click Events
    click B "https://github.com/alucrece/deploiement_continu/tree/main/my-app/"
    click B "https://github.com/alucrece/deploiement_continu/tree/main/my-app/Dockerfile"
    click B "https://github.com/alucrece/deploiement_continu/blob/main/my-app/package.json"
    click B "https://github.com/alucrece/deploiement_continu/blob/main/my-app/package-lock.json"
    click B "https://github.com/alucrece/deploiement_continu/tree/main/my-app/src/tests/"
    click B "https://github.com/alucrece/deploiement_continu/blob/main/my-app/src/utils/validation.js"
    click B "https://github.com/alucrece/deploiement_continu/blob/main/my-app/src/components/registrationForm.js"
    click B "https://github.com/alucrece/deploiement_continu/tree/main/my-app/cypress/"
    click B "https://github.com/alucrece/deploiement_continu/blob/main/my-app/.github/workflows/build_test.yml"
    click B "https://github.com/alucrece/deploiement_continu/tree/main/my-app/public/"
    click B "https://github.com/alucrece/deploiement_continu/blob/main/my-app/src/index.js"
    click C "https://github.com/alucrece/deploiement_continu/blob/main/server/server.py"
    click C "https://github.com/alucrece/deploiement_continu/tree/main/server/DockerfilePython"
    click C "https://github.com/alucrece/deploiement_continu/blob/main/server/requirements.txt"
    click C "https://github.com/alucrece/deploiement_continu/blob/main/server/package.json"
    click C "https://github.com/alucrece/deploiement_continu/blob/main/server/package-lock.json"
    click C "https://github.com/alucrece/deploiement_continu/tree/main/server/coverage/"
    click C "https://github.com/alucrece/deploiement_continu/blob/main/server/vercel.json"
    click D "https://github.com/alucrece/deploiement_continu/tree/main/SQLFiles/"
    click E "https://github.com/alucrece/deploiement_continu/blob/main/SQLFiles/migration-v001.sql"
    click E "https://github.com/alucrece/deploiement_continu/blob/main/SQLFiles/migration-v002.sql"
    click F "https://github.com/alucrece/deploiement_continu/blob/main/docker-compose.yml"
    click G "https://github.com/alucrece/deploiement_continu/blob/main/.github/workflows/build_test.yml"
    click I "https://github.com/alucrece/deploiement_continu/blob/main/.github/workflows/build_test_deploy_react.yml"
    click H "https://github.com/alucrece/deploiement_continu/blob/main/.codecov.yml"
    click L "https://github.com/alucrece/deploiement_continu/blob/main/README.md"

    %% Styles
    classDef frontend fill:#ADD8E6,stroke:#333,stroke-width:1px
    classDef backend fill:#90EE90,stroke:#333,stroke-width:1px
    classDef database fill:#FFA500,stroke:#333,stroke-width:1px
    classDef infra fill:#D3D3D3,stroke:#333,stroke-width:1px
    classDef ci fill:#D3D3D3,stroke:#333,stroke-width:1px
    classDef external fill:#D3D3D3,stroke:#333,stroke-width:1px
```
