Search by

drago-ex / project-docker-db

accgit

The package extends the Drago Project to include mysqli database on docker.

Package info

github.com/drago-ex/project-docker-db

Type:drago-tools-resource

pkg:composer/drago-ex/project-docker-db

Statistics

Installs: 154

Dependents: 2

Suggesters: 0

Stars: 0

Open Issues: 0

v1.2.0 2026-10-31 14:45 UTC

This package is auto-updated.

Last update: 2026-11-05 18:04:06 UTC


README

A MariaDB database in Docker for Drago Project, the mysqli extension in the PHP image and the database connection of the application (Dibi).

PHP version Coding Style

Requirements

Installation

composer require drago-ex/project-docker-db

Project Tools copies docker-compose.override.yaml, the Dockerfile of the database image and local/db.neon into the project. Build the images again afterwards (npm run docker:build).

Usage

  • The database app runs as the service db; the connection of the application is in local/db.neon (keep it out of git). docker compose watch (npm run docker:dev) copies its changes into the container.
  • The data are in the Docker volume db-data. docker compose down keeps them, docker compose down --volumes deletes them.
  • The database listens on 127.0.0.1:6033, so tools on your computer can connect to it. DB_PORT=6033 publishes it on every interface; Docker bypasses firewalls such as ufw, so never do so on a server.

Development Only

The user and passwords (super/pass, root root) in docker-compose.override.yaml and local/db.neon are for local development. Change them before the setup runs anywhere else; the docker:production script uses the same files.