Ubuntu 24.04 container running Laravel 13 with an integrated MySQL for all-in-one deployments
3.1K
This is a generalized, all-in-one Docker image designed to support modern PHP applications (like Laravel 13+) that require a classic LAMP (Linux, Apache, MariaDB, PHP) stack.
It serves as the base layer for projects like Godzilla TCG DB, abstracting away system dependencies, PHP extension compilation, and database initialization into a single reusable container.
php:8.4-apachemariadb-server (Debian's default MySQL equivalent)pdo_mysql, gd, zip, bcmathcomposer (latest), git, unzipBy default, Apache serves files from /var/www/html. You can override this dynamically in your downstream Dockerfile by setting the APACHE_DOCUMENT_ROOT environment variable:
ENV APACHE_DOCUMENT_ROOT=/var/www/public
By default, the container starts MariaDB automatically. If your application relies on an external database (e.g., hosted outside the container or via another Docker Compose service), you can disable the local database startup by setting START_MYSQL to false:
ENV START_MYSQL=false
To use this image as a base layer for your application, reference it in your project's Dockerfile:
FROM ikaruwa/lamp_base:latest
# Set custom Apache root
ENV APACHE_DOCUMENT_ROOT=/var/www/public
# Disable local DB if using an external one
ENV START_MYSQL=false
COPY . /var/www
WORKDIR /var/www
RUN composer install
This repository includes a GitHub Action (.github/workflows/docker-publish.yml) that automatically builds and pushes the image to Docker Hub at ikaruwa/lamp_base:latest whenever changes are pushed to the main branch.
Content type
Image
Digest
sha256:722ddb1be…
Size
247.6 MB
Last updated
about 1 month ago
docker pull ikaruwa/lamp_base