Skip to content

A simple Docker-based PHP, NGINX, MariaDB, Redis, and phpMyAdmin stack for fast local development.

Notifications You must be signed in to change notification settings

FTMahringer/BASE-Webserver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🚀 FTM Docker Web Stack

This project sets up a modern PHP development environment using Docker, including:

NGINX (web server) ✅ PHP-FPM (with custom php.ini) ✅ MariaDB (MySQL-compatible database) ✅ phpMyAdmin (database web UI) ✅ Redis (caching) ✅ RedisInsight (visual Redis browser)


🏦 What’s Inside?

Service Description
NGINX Lightweight web server with custom config
PHP-FPM FastCGI PHP engine with tuned PHP settings
MariaDB MySQL-compatible database for development
phpMyAdmin Web interface to manage MariaDB
Redis Fast in-memory key-value store
RedisInsight UI to explore and debug Redis data

🏗️ Project Structure

.
├── app/               → Your PHP project code goes here
├── docker/
│   ├── nginx/
│   │   └── nginx.conf → Custom NGINX configuration
│   ├── php/
│   │   ├── Dockerfile → Custom PHP build (with extensions/settings)
│   │   └── php.ini    → Custom PHP settings
├── docker-compose.yml → Orchestrates all services
└── .env               → Environment variables for the stack

⚙️ Quick Start

1️⃣ Clone the repo

git clone https://github.com/FTMahringer/Base-Webserver.git
cd BASE-Webserver

2️⃣ Create your .env

Already provided, but adjust as needed:

MYSQL_ROOT_PASSWORD=rootpassword
MYSQL_DATABASE=dbname
MYSQL_USER=user
MYSQL_PASSWORD=password
PMA_HOST=mariadb

3️⃣ Start the stack

docker compose up -d --build

4️⃣ Access services


🛠️ Customizations

  • Nginx configdocker/nginx/nginx.conf
  • PHP settingsdocker/php/php.ini
  • Dockerfile for PHPdocker/php/Dockerfile

You can modify these to fit your project’s needs.


💡 Notes

  • Database data persists in the mariadb_data volume.
  • Redis data persists in the redis_data volume.
  • NGINX logs are saved in the nginx_logs volume.

To clear everything (⚠ will delete all data):

docker compose down -v

👌 Credits

Created by Fynn Mahringer (FTM) If you use this, feel free to ⭐ star the repo and contribute!

About

A simple Docker-based PHP, NGINX, MariaDB, Redis, and phpMyAdmin stack for fast local development.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published