-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
executable file
·58 lines (51 loc) · 1.2 KB
/
docker-compose.yaml
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
48
49
50
51
52
53
54
55
56
57
58
version: '3'
services:
frontend:
image: frontend-image
build: ./frontend
ports:
- "8080:80"
volumes:
- ./frontend:/var/www/html # bind mount the frontend code to container
# networks:
# - app-network
# api:
# image: api-image
# build: ./api
# ports:
# - "8081:80"
# environment:
# - DATABASE_HOST=db
# volumes:
# - ./api:/var/www/html # bind mount the API code to container
# networks:
# - app-network
# depends_on:
# - db
# db:
# image: mysql:5.7
# environment:
# MYSQL_DATABASE: ecommerce # This should match your database name
# MYSQL_USER: user
# MYSQL_PASSWORD: password
# MYSQL_ROOT_PASSWORD: password
# volumes:
# - db-data:/var/lib/mysql
# - ./db/ecommerce.sql:/docker-entrypoint-initdb.d/ecommerce.sql # Mount the SQL file
# networks:
# - app-network
# phpmyadmin:
# image: phpmyadmin/phpmyadmin
# environment:
# PMA_HOST: db
# PMA_USER: user
# PMA_PASSWORD: password
# ports:
# - "8082:80"
# networks:
# - app-network
# networks:
# app-network:
# driver: bridge
# volumes:
# db-data: