Skip to content

LAMP (Linux - Apache - Mariadb - PHP) Server using docker compose.

License

Notifications You must be signed in to change notification settings

techwithus/LAMP-Server-Docker-Compose

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LAMP Server Docker Compose

Introduction

This repository can be used to host LAMP (Linux, Apache, Mariadb, PHP) server using docker compose. The docker images used for building LAMP stack are:-

  1. php:7.4-apache
  2. mariadb:10.5.1-bionic
  3. phpmyadmin/phpmyadmin

Instructions

  1. The default configuration is saved as sample_env. Copy contents from sample_env to .env.

    $ cp sample_env .env

  2. Make necessary changes to .env file.

  3. Build docker-compose image using the following command.

    $ docker-compose build --no-cache

  4. Run docker-compose using the following command.

    $ docker-compose up -d

  5. To shut down docker-compose container, using the following command.

    $ docker-compose down

Folder structure

  1. bin: Contains Dockerfile for each docker image.
  2. config: Contains configurations for apache2, php and vhosts.
  3. data: Contains data generated by docker containers.
  4. logs: Contains logs from docker containers.

Contributors

  1. Sashwat K sashwat0001@gmail.com