Docker running Apache, PHP-FPM, MySQL Adminer, RabbitMQ and PHPMyAdmin.
Docker running Apache, PHP-FPM, MySQL Adminer, RabbitMQ and PHPMyAdmin.
Before installing project make sure the following prerequisites have been met.
We’ll download the code from its repository on GitHub.
By this point we’ll have all the project pieces in place.
When running, you can use docker commands for doing recurrent operations.
For now, this project has been mainly created for Unix (Linux/MacOS)
. Perhaps it could work on Windows.
All requisites should be available for your distribution. The most important are :
Check if docker-compose
is already installed by entering the following command :
which docker-compose
On Ubuntu and Debian these are available in the meta-package build-essential. On other distributions, you may need to install the GNU C++ compiler separately.
sudo apt install build-essential
This project use the following ports :
Server | Port |
---|---|
mariadb | 3306 |
adminer | 8080 |
PHPMyAdmin | 80 |
apache | 80/433 |
RabbitMQ | 15672 |
To install Git, download it and install following the instructions :
git clone https://github.com/MarshallJamesRaynor/mementodockeruse.git
Go to the project directory :
cd mementodockeruse
/memento-docker-use/
├── dev
│ ├── config
│ │ └── apache2
│ │ └── sites
│ ├── docker
│ │ ├── adminer
│ │ │ ├── Dockerfile
│ │ ├── apache
│ │ │ ├── Dockerfile
│ │ │ └── dev.apache.conf
│ │ ├── apache
│ │ │ └── Dockerfile
│ │ ├── mariadb
│ │ │ └── Dockerfile
│ │ ├── php
│ │ │ └── Dockerfile
│ │ ├── phpmyadmin
│ │ │ └── Dockerfile
│ │ └── rabbitmq
│ │ └── Dockerfile
│ ├── documentation
│ │ └── command.md
│ ├── logs
│ │ └── apache2
│ └── scripts
│ └── hosts.sh
├── public_html
│ └── index.php
├── .editorconfig
├── .env
├── .gitignore
├── composer.json
├── docker-compose.yml
├── LICENSE
├── Makefile
└── README.md
One of the main features of this project is the ability to manage the environment from the project directory itself.
The starter includes a Makefile to simplify the basic tasks:
Start the application :
make start
Please wait this might take a several minutes…
sh dev/scripts/hosts.sh
Open your favorite browser :
Stop and clear services
make stop
Here are other several commands that you can now use from your project directory.
build
Build the environmentrebuild
force a rebuild by passing —no-cachelogs
Follow logs generated by all containerslogs-full
Follow logs generated by all containers from the containers creationphp
Open a terminal in the “php” containerapache
Open a terminal in the “apache” containerps
List all containers managed by the environmentstart
Start the environmentstats
Print real-time statistics about containers ressources usagestop
Stop the environmentdestroy
destroy the environmentprune
clean all that is not actively usedhelp
show list commandAny thought, feedback or (hopefully not!) issue.