-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
47 lines (43 loc) · 1008 Bytes
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
version: '3'
services:
app:
build:
context: .
dockerfile: Dockerfile
image: your-laravel-app
ports:
- "9000:9000" # Map host port 9000 to container port 9000
volumes:
- .:/var/www/html
depends_on:
- db
db:
image: mysql:8.1
restart: unless-stopped
environment:
MYSQL_ROOT_PASSWORD: your_project@root123
MYSQL_DATABASE: your_project
ports:
- "3306:3306" # Map host port 3306 to MySQL port 3306
volumes:
- mysql_data:/var/lib/mysql
phpmyadmin:
image: phpmyadmin/phpmyadmin
environment:
MYSQL_ROOT_PASSWORD: your_project@root123
PMA_HOST: db
PMA_PORT: 3306
ports:
- "8080:80" # Map host port 8080 to phpMyAdmin port 80
depends_on:
- db
nginx:
image: nginx:latest
ports:
- "8000:80" # Map host port 8000 to Nginx port 80
volumes:
- ./nginx/default.conf:/etc/nginx/conf.d/default.conf
depends_on:
- app
volumes:
mysql_data: