-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
42 lines (39 loc) · 868 Bytes
/
docker-compose.yml
File metadata and controls
42 lines (39 loc) · 868 Bytes
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
version: '3'
services:
db:
image: mysql:latest
environment:
MYSQL_ROOT_PASSWORD: rassword
MYSQL_USER: user
MYSQL_PASSWORD: password
MYSQL_DATABASE: counter_db
volumes:
- ./data:/var/lib/mysql
# import sql file to give permissions to user
# - ./init.sql:/docker-entrypoint-initdb.d/init.sql
ports:
- "3306:3306"
phpmyadmin:
image: phpmyadmin/phpmyadmin
environment:
PMA_HOST: db
MYSQL_ROOT_PASSWORD: rassword
ports:
- "8080:8080"
depends_on:
- db
nodejs:
image: node:latest
working_dir: /app
volumes:
- ./src:/app
ports:
- "3001:80"
environment:
- MYSQL_HOST=db
- MYSQL_USER=user
- MYSQL_PASSWORD=password
- MYSQL_DATABASE=counter_db
depends_on:
- db
command: npx nodemon ./server.js