This repository contains the Docker setup for a Laravel application with the following services:
- PHP
- Nginx
- MySQL
- phpMyAdmin
- Adminer
- Redis
Make sure you have Docker and Docker Compose installed on your system.
-
Clone the repository and navigate to the project directory:
git clone <repository-url> laradoc cd laradoc
-
Build and start the Docker containers:
docker compose up -d --build
-
Set permissions for phpMyAdmin sessions:
docker compose exec phpmyadmin chmod 777 /sessions
-
Access the PHP container:
docker compose exec -it php bash
-
Inside the PHP container, set the necessary permissions for Laravel:
chown -R www-data:www-data /var/www/storage /var/www/bootstrap/cache chmod -R 775 /var/www/storage /var/www/bootstrap/cache
-
Install Composer dependencies:
composer install
To start the Docker containers after the initial setup, simply run:
docker compose up -d
URL: http://localhost
phpMyAdmin: 8080
Adminer : 9090
MySQL : 3306
- Note: This setup is intended for development purposes only. For production use, please review and adjust the configurations as needed.