-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
executable file
·59 lines (58 loc) · 1.44 KB
/
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
48
49
50
51
52
53
54
55
56
57
58
59
#docker-compose.yml
version: '3'
services:
nginx:
container_name: nginx-laravel-mongodb
image: nginx:1.17.8
command: [ "nginx", "-g", "daemon off;" ]
depends_on:
- app
links:
- app
working_dir: /var/www/html
volumes:
- ./docker/nginx/asset/:/etc/nginx/conf.d/
- ./docker/nginx/log:/var/log/nginx/:rw
- ./:/var/www/html:rw
ports:
- "8080:80"
logging:
options:
max-size: "1m"
max-file: "3"
networks:
- local-network
app:
container_name: app-laravel-mongodb
build: ./docker/php
working_dir: /var/www/html
links:
- db
depends_on:
- db
volumes:
- ./:/var/www/html:rw
command: bash -c "php-fpm"
logging:
options:
max-size: "1m"
max-file: "3"
networks:
- local-network
db:
container_name: db-laravel-mongodb
image: mongo:4.2
volumes:
- './dbdata:/data/db'
ports:
- 27018:27017
environment:
MONGO_INITDB_ROOT_USERNAME: root
MONGO_INITDB_ROOT_PASSWORD: password123
restart: always
logging:
driver: none
networks:
- local-network
networks:
local-network: