-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
78 lines (72 loc) · 2.25 KB
/
docker-compose.yml
File metadata and controls
78 lines (72 loc) · 2.25 KB
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
version: '3'
services:
traefik:
image: traefik:latest
ports:
- 80:80
- 443:443
- 8080:8080 # (optional) expose the dashboard - don't use in production?
- 9001:9001 # phpMyAdmin
volumes:
- ./.config/local/traefik/traefik.yml:/etc/traefik/traefik.yml
- ./.config/local/certs:/certs
- /var/run/docker.sock:/var/run/docker.sock:ro
restart: unless-stopped
php:
image: carletonuniversity/cu-events-api:develop
restart: always
volumes:
- ./laravel:/var/www/html
- ./.config/local/php/fpm-pool.conf:/usr/local/etc/php-fpm.d/zzz.conf
- ./.config/local/php/php.ini:/usr/local/etc/php/conf.d/local.ini
env_file:
- ./.config/local/env/laravel.env
nginx:
image: nginx:latest
volumes:
- ./laravel:/var/www/html
- ./.config/local/nginx/default.conf:/etc/nginx/conf.d/default.conf
- ./.config/local/certs:/etc/nginx/certs
depends_on:
- php
labels:
- 'traefik.enable=true'
- 'traefik.http.routers.nginx.rule=Host(`localhost`)'
- 'traefik.http.routers.nginx.entrypoints=web,websecure'
- 'traefik.http.routers.nginx.tls=true'
- 'traefik.http.middlewares.nginx.compress=true'
- 'traefik.http.services.nginx.loadbalancer.server.port=80' # Specify the correct port for NGINX
mysql:
image: mysql:latest
command: --default-authentication-plugin=mysql_native_password
volumes:
- ./.config/data/mysql:/var/lib/mysql
- ./.config/data/logs/mysql:/var/log/mysql
- ./.config/local/mysql:/etc/mysql/conf.d
environment:
- MYSQL_DATABASE=api
- MYSQL_ROOT_PASSWORD=password
- MYSQL_PASSWORD=password
- MYSQL_ROOT_HOST=%
cap_add:
- SYS_NICE
restart: always
ports:
- '3307:3306'
redis:
image: 'redis:alpine'
command: redis-server
expose:
- '6379'
phpmyadmin:
image: phpmyadmin/phpmyadmin
environment:
- PMA_HOST=mysql
- PMA_USER=root
- PMA_PASSWORD=password
labels:
- 'traefik.enable=true'
- 'traefik.http.routers.phpmyadmin.rule=Host(`localhost`)'
- 'traefik.http.routers.phpmyadmin.entrypoints=phpmyadmin'
- 'traefik.http.services.phpmyadmin.loadbalancer.server.port=80'
restart: always