A ready-to-use collection of common development services (databases, caches, queues, and more) managed through Docker Compose. Run all your shared services from one place instead of duplicating them across every project.
When working on multiple projects at the same time, each project often comes with its own set of services like MySQL, Redis, or RabbitMQ. Running duplicate copies of the same service wastes system resources and makes it hard to keep track of ports and configurations.
Docker Commons solves this by letting you:
- Run shared services (databases, caches, queues, etc.) once and connect any project to them.
- Pick only the services you need — no need to start everything.
- Use simple network aliases (e.g.
common-mysql,common-redis) so your apps can find services easily. - Keep all service settings in one place, making them easy to update.
Inspired by LaraDock.
Each service that needs extra setup or has special instructions has its own documentation inside its folder. See the links in the Services table below.
| Document | Description |
|---|---|
| Adminer Docs | Database management UI notes |
| Cassandra DSE Docs | DataStax Enterprise configuration details |
| Elasticsearch Docs | Password setup, certificate generation |
| Flagr Docs | Feature flag service overview |
| MinIO Docs | S3-compatible object storage notes |
| MySQL Docs | MySQL references and links |
| MySQL Slave Docs | MySQL replication setup |
| NFS Server Docs | NFS mount/unmount instructions |
| Volume Backup & Restore Docs | Backup and restore Docker volumes |
Below is the full list of services included in this project. The Compose Name is what you use in docker compose up -d <name> commands. The Network Alias is the hostname your application uses to connect to the service.
| Name | Compose Name | Description | Docs | Build Required | Network Alias |
|---|---|---|---|---|---|
| Adminer | adminer | Web UI for managing databases (MySQL, Postgres, Mongo, etc.) | Docs | ||
| Apache Druid | apache_druid_* | Real-time analytics database (coordinator, broker, historical, middlemanager, router) | |||
| Apache Zookeeper | zookeeper | Distributed coordination service for Apache Druid and others | |||
| Blackfire | blackfire | PHP performance profiling and monitoring tool | common-blackfire | ||
| Cassandra | cassandra | Distributed NoSQL database for large-scale data | common-cassandra | ||
| Cassandra DSE | cassandra-node1/2/3 | DataStax Enterprise Cassandra multi-node cluster | Docs | Yes | |
| Dragonflydb | dragonfly | High-performance in-memory datastore, drop-in Redis replacement | common-dragonfly | ||
| Elasticsearch | elasticsearch | Search and analytics engine for log analysis, full-text search, and more | Docs | Yes | common-elasticsearch |
| Flagr | flagr | Feature flagging and A/B testing microservice | Docs | Yes | common-flagr |
| Fluentd | fluentd | Log collector and aggregator | Yes | ||
| Grafana | grafana | Metrics visualization and monitoring dashboards | |||
| Jaeger | jaeger | Distributed tracing for monitoring microservices | common-jaeger | ||
| Jenkins | jenkins | CI/CD automation server | common-jenkins | ||
| Kibana | kibana | Visualization dashboard for Elasticsearch data | Yes | ||
| MailDev | maildev | Email testing tool — catches outgoing emails for inspection | common-maildev | ||
| Mailhog | mailhog | SMTP testing server with a web UI to view caught emails | common-mailhog | ||
| MinIO | minio | S3-compatible object storage | Docs | common-minio | |
| MinIO Client (MC) | minio-client | CLI tool for managing MinIO buckets and objects | |||
| MinIO Nginx | minio-nginx | Reverse proxy for MinIO API and console | |||
| MongoDB | mongo | NoSQL document database | common-mongo | ||
| MySQL | mysql | Popular relational database | Docs | common-mysql | |
| NFS Server | nfs-server | Simple NFS file server for local testing | Docs | ||
| OpenLDAP | ldap | Lightweight directory access protocol server | common-ldap | ||
| Oracle XE | oracle | Oracle Express Edition database | Yes | common-oracle | |
| Portainer | portainer | Web UI for managing Docker containers and images | |||
| PostgreSQL | postgres | Advanced open-source relational database | common-postgres | ||
| RabbitMQ | rabbitmq | Message broker for queuing and async communication | common-rabbitmq | ||
| Redis | redis | In-memory data store used for caching and sessions | common-redis | ||
| Redis Commander | redis-commander | Web UI for browsing Redis data | |||
| Redis Sentinel | redis-sentinel | High-availability monitor for Redis | common-redis-sentinel | ||
| Redis Stack | redis-stack | Redis with built-in search, JSON, and time-series modules | |||
| RediSearch | redisearch | Redis with full-text search capabilities | Yes | common-redisearch | |
| SFTP | sftp | Secure file transfer server | common-sftp | ||
| Traefik | traefik | Reverse proxy and load balancer for routing HTTP traffic | traefik | ||
| Volume Backup | volume-backup | Utility to back up Docker named volumes | Docs | ||
| Volume Restore | volume-restore | Utility to restore Docker named volumes | Docs |
- Elasticsearch & Kibana — Require a custom image build. On first start, Elasticsearch generates a password you will need. See Elasticsearch Docs for details.
- Cassandra DSE — Runs as a multi-node cluster (3 nodes). Default credentials are
cassandra/cassandra. See Cassandra DSE Docs. - NFS Server — After starting, you must mount the NFS share on your host. See Service Specific Details below for commands.
- Apache Druid — Requires Apache Zookeeper to be running. Start both together:
docker compose up -d zookeeper apache_druid_coordinator apache_druid_broker apache_druid_historical apache_druid_middlemanager apache_druid_router.
- Fully supported. All services work natively.
- Use
copy-examples.shto create configuration files. - Use
:as the path separator in the.envfile forCOMPOSE_PATH_SEPARATOR.
- Supported. Use
bash copy-examples.shto create configuration files. - Use
:as the path separator in the.envfile forCOMPOSE_PATH_SEPARATOR.
- Use
copy-examples.batto create configuration files. - Use
;as the path separator in the.envfile forCOMPOSE_PATH_SEPARATOR. - If your system supports WSL2, it is highly recommended to use that instead of running Docker directly on Windows.
- The following services do not work on a Windows host and require WSL2:
- NFS Server
- Docker Engine v20.10+ / Docker Desktop v4.0+
- Docker Compose v2.7+ (Use
docker composecommand)- or v1.29+ (Use
docker-composecommand)
- or v1.29+ (Use
- Open a terminal or command prompt.
- Clone this repository and
cdinto the directory. Opening it in an IDE is helpful. - Create configuration files from the provided examples. Run the appropriate script for your OS (see Operating System Notes above), or copy the files manually. Do not delete the example files — they are kept for reference.
.env.example→.envdocker-compose.override.example.yml→docker-compose.override.yml.envs/{name}.example.env→.envs/{name}.env
- Edit
.envand update values for your environment:COMPOSE_FILE— List thedocker-compose.override.{name}.ymlfiles for the services you want. Keepdocker-compose.override.ymlat the end.COMPOSE_PATH_SEPARATOR— Use:on Linux/macOS or;on Windows.- Other settings are documented as comments inside the file.
- Edit
docker-compose.override.yml:- Remove service sections you do not need.
- Adjust any settings as required.
- Edit files in
.envs/{name}.envas needed for each service. - Pull the Docker images:
If it stops due to a network error, just run it again.
docker compose pull
- Create the shared Docker network:
docker network create common-net
- (Optional) If using Traefik, create its network:
docker network create common-traefik-net
- (Optional) If using services that require a custom image build (see the Services table), build them:
docker compose build <service-name>
- Start all services:
docker compose up -d
- Start specific services only:
Example:
docker compose up -d <service1> <service2> ...
docker compose up -d adminer mysql
- View running services:
docker compose ps
- View logs for a specific service:
docker compose logs --tail=100 <service-name>
- Stop all services:
docker compose down
- Stop specific services only:
Example:
docker compose rm -sf <service1> <service2> ...
docker compose rm -sf adminer mysql
Connect your application's Docker network to common-net and use the service's network alias as the hostname and the container port as the port number.
For example, to connect to MySQL, add this to your application's docker-compose.yml:
networks:
common-net:
external: true
services:
myapp:
...
networks:
- common-net
...Then in your application's database configuration:
- Host:
common-mysql - Port:
3306
Restart your application container and it will be able to reach MySQL. This same approach works for all services that have a network alias.
After starting the NFS container, mount it on your host machine. First find the container's IP (e.g. using ifconfig or hostname -I), then run:
sudo mount -v -o vers=4,loud <container-ip>:/ /path/to/mountImportant: Always unmount before shutting down your machine to avoid issues:
sudo umount /path/to/mountThis project is designed for local development. It can be adapted for production, but you may need to change security settings, use different images, or mount custom configuration files. Always review security concerns before deploying any of these services in a production environment.
- Make it work with Podman.
This project is licensed under the terms of the MIT License.