forked from ucfopen/UDOIT
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.nginx.yml
71 lines (69 loc) · 1.52 KB
/
docker-compose.nginx.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
version: "3.9"
services:
db:
image: mysql:latest
volumes:
- dbdata:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: udoit3
MYSQL_USER: udoit
MYSQL_PASSWORD: udoit
ports:
- "3306:3306"
# Uncomment this block and comment the next db block
# to use Postgres instead of MySQL
# db:
# image: postgres:alpine
# restart: always
# ports:
# - "5432:5432"
# environment:
# POSTGRES_USER: udoit
# POSTGRES_PASSWORD: udoit
# POSTGRES_DB: udoit3
web:
image: nginx:latest
ports:
- "8000:80"
volumes:
- .:/var/www/html
- ./build/nginx/local.conf:/etc/nginx/conf.d/default.conf
links:
- php
env_file:
- .env
php:
build:
context: ./build/nginx
dockerfile: Dockerfile.php.pdo.mysql
volumes:
- ./:/var/www/html
- type: bind
source: ./build/nginx/php-custom.ini
target: /usr/local/etc/php/conf.d/php-custom.ini
env_file:
- .env
composer:
build:
context: ./build/nginx
dockerfile: Dockerfile.composer
command: "composer install --no-dev --no-interaction --no-progress --optimize-autoloader"
volumes:
- ./:/app
env_file:
- .env
yarn:
image: node:16
volumes:
- ./:/app
env_file:
- .env
command: >
bash -c '
cd /app &&
yarn install &&
yarn build'
volumes:
web:
dbdata: