# sprintcube/docker-compose-lamp architecture

> Architecture diagram of the GitHub repository sprintcube/docker-compose-lamp, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-05). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sprintcube/docker-compose-lamp
- Repository: https://github.com/sprintcube/docker-compose-lamp

## Overview

This repository provides a Docker Compose local-development stack: a developer starts the services, then visits the local web server to use the sample PHP site and supporting tools. The README documents PHP version selection, database initialization and persistence, virtual hosts, optional HTTPS, phpMyAdmin, Redis, and Xdebug. The Compose definition and most runtime configuration were not excerpted, so service wiring beyond documented behavior is omitted or shown only where README evidence supports it.

Main entry points: [`docker-compose.yml`](https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml) (Compose stack), [`bin`](https://github.com/sprintcube/docker-compose-lamp/tree/master/bin) (MySQL / MariaDB), [`www/index.php`](https://github.com/sprintcube/docker-compose-lamp/blob/master/www/index.php) (Landing page), [`logs`](https://github.com/sprintcube/docker-compose-lamp/tree/master/logs) (Service logs)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Runtime services"]
  node_compose["Compose stack<br/>[docker-compose.yml]"]
  node_apache["Apache<br/>[docker-compose.yml]"]
  node_php["PHP runtime"]
  node_database[("MySQL / MariaDB")]
  node_pma["phpMyAdmin<br/>[docker-compose.yml]"]
  node_redis["Redis<br/>[docker-compose.yml]"]
end

subgraph group_configuration["Configuration and state"]
  node_vhosts["Virtual hosts / SSL<br/>[default.conf]"]
  node_phpconfig["PHP configuration<br/>[php.ini]"]
  node_dbinit["Database initialization"]
  node_dbdata[("Database files")]
  node_logs["Service logs"]
end

subgraph group_site["Sample site"]
  node_site["Landing page<br/>[index.php]"]
  node_phpinfo["PHP info page<br/>[phpinfo.php]"]
  node_dbtests["Database test pages"]
end

node_developer(("Developer"))
node_browser(("Browser"))

node_developer -->|"starts"| node_compose
node_compose -->|"starts"| node_apache
node_compose -->|"starts"| node_php
node_compose -->|"starts"| node_database
node_compose -->|"starts"| node_pma
node_compose -->|"starts"| node_redis
node_browser -->|"requests pages"| node_apache
node_apache -->|"serves"| node_site
node_browser -->|"opens"| node_phpinfo
node_browser -->|"opens"| node_dbtests
node_site -->|"connects to"| node_database
node_browser -->|"opens"| node_pma
node_apache -->|"uses"| node_vhosts
node_php -->|"uses"| node_phpconfig
node_database -->|"executes"| node_dbinit
node_database -->|"persists to"| node_dbdata
node_apache -->|"writes logs"| node_logs
node_database -->|"writes logs"| node_logs

click node_compose "https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml"
click node_apache "https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml"
click node_php "https://github.com/sprintcube/docker-compose-lamp/tree/master/bin"
click node_database "https://github.com/sprintcube/docker-compose-lamp/tree/master/bin"
click node_pma "https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml"
click node_redis "https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml"
click node_site "https://github.com/sprintcube/docker-compose-lamp/blob/master/www/index.php"
click node_phpinfo "https://github.com/sprintcube/docker-compose-lamp/blob/master/www/phpinfo.php"
click node_dbtests "https://github.com/sprintcube/docker-compose-lamp/tree/master/www"
click node_vhosts "https://github.com/sprintcube/docker-compose-lamp/blob/master/config/vhosts/default.conf"
click node_phpconfig "https://github.com/sprintcube/docker-compose-lamp/blob/master/config/php/php.ini"
click node_dbinit "https://github.com/sprintcube/docker-compose-lamp/tree/master/config/initdb"
click node_dbdata "https://github.com/sprintcube/docker-compose-lamp/tree/master/data/mysql"
click node_logs "https://github.com/sprintcube/docker-compose-lamp/tree/master/logs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_compose,node_apache,node_php,node_database,node_pma,node_redis,node_browser toneBlue
class node_vhosts,node_phpconfig,node_dbinit,node_dbdata,node_logs toneAmber
class node_site,node_phpinfo,node_dbtests toneMint
class node_developer toneIndigo
```

## Components

### Runtime services

- [Compose stack](https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml): `docker-compose.yml`
- [Apache](https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml): `docker-compose.yml`
- [PHP runtime](https://github.com/sprintcube/docker-compose-lamp/tree/master/bin): `bin`
- [MySQL / MariaDB](https://github.com/sprintcube/docker-compose-lamp/tree/master/bin): `bin`
- [phpMyAdmin](https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml): `docker-compose.yml`
- [Redis](https://github.com/sprintcube/docker-compose-lamp/blob/master/docker-compose.yml): `docker-compose.yml`

### Configuration and state

- [Virtual hosts / SSL](https://github.com/sprintcube/docker-compose-lamp/blob/master/config/vhosts/default.conf): `config/vhosts/default.conf`
- [PHP configuration](https://github.com/sprintcube/docker-compose-lamp/blob/master/config/php/php.ini): `config/php/php.ini`
- [Database initialization](https://github.com/sprintcube/docker-compose-lamp/tree/master/config/initdb): `config/initdb`
- [Database files](https://github.com/sprintcube/docker-compose-lamp/tree/master/data/mysql): `data/mysql`
- [Service logs](https://github.com/sprintcube/docker-compose-lamp/tree/master/logs): `logs`

### Sample site

- [Landing page](https://github.com/sprintcube/docker-compose-lamp/blob/master/www/index.php): `www/index.php`
- [PHP info page](https://github.com/sprintcube/docker-compose-lamp/blob/master/www/phpinfo.php): `www/phpinfo.php`
- [Database test pages](https://github.com/sprintcube/docker-compose-lamp/tree/master/www): `www`

### Other components

- **Developer**
- **Browser**

## Connections

- Developer → Compose stack: starts (evidence: `README.md`)
- Compose stack → Apache: starts (evidence: `README.md`)
- Compose stack → PHP runtime: starts (evidence: `README.md`)
- Compose stack → MySQL / MariaDB: starts (evidence: `README.md`)
- Compose stack → phpMyAdmin: starts (evidence: `README.md`)
- Compose stack → Redis: starts (evidence: `README.md`)
- Browser → Apache: requests pages (evidence: `README.md`)
- Apache → Landing page: serves (evidence: `README.md`)
- Browser → PHP info page: opens
- Browser → Database test pages: opens (evidence: `www/index.php`)
- Landing page → MySQL / MariaDB: connects to (evidence: `www/index.php`)
- Browser → phpMyAdmin: opens
- Apache → Virtual hosts / SSL: uses (evidence: `README.md`)
- PHP runtime → PHP configuration: uses (evidence: `README.md`)
- MySQL / MariaDB → Database initialization: executes (evidence: `README.md`)
- MySQL / MariaDB → Database files: persists to (evidence: `README.md`)
- Apache → Service logs: writes logs (evidence: `README.md`)
- MySQL / MariaDB → Service logs: writes logs (evidence: `README.md`)
