forked from trandafirdaniela/practica2021
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
73 lines (69 loc) · 1.83 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
version: '3'
services:
practica-nginx:
container_name: practica-nginx
build:
context: ./
dockerfile: docker/nginx/Dockerfile
args:
VHOST_FILE: ${VHOST_FILE}
volumes:
- ./:/var/www
ports:
- 80
depends_on:
- practica-php
environment:
VIRTUAL_HOST: ${DOMAIN_HOSTS}
VIRTUAL_PORT: 80
LETSENCRYPT_HOST: ${DOMAIN_HOSTS}
LETSENCRYPT_EMAIL: ${LETSENCRYPT_EMAIL}
networks:
- nginx-proxy
- practica
practica-php:
container_name: practica-php
build:
context: ./
dockerfile: docker/php/Dockerfile
volumes:
- ./:/var/www
depends_on:
- practica-mysql
- practica-redis
ports:
- 9000
networks:
- practica
practica-mysql:
container_name: practica-mysql
build:
context: ./
dockerfile: docker/mysql/Dockerfile
command: --default-authentication-plugin=mysql_native_password
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_DATABASE: ${DB_DATABASE}
MYSQL_USER: ${DB_USERNAME}
MYSQL_PASSWORD: ${DB_PASSWORD}
ports:
- ${DB_EXTERNAL_PORT}:3306
networks:
- practica
practica-redis:
container_name: practica-redis
build:
args:
REDIS_PASSWORD: ${REDIS_PASSWORD}
context: ./
dockerfile: docker/redis/Dockerfile
ports:
- 6379
sysctls:
- net.core.somaxconn=511
networks:
- practica
networks:
practica:
nginx-proxy:
external: true