Repository navigation
Expand file tree
/
Copy pathcompose.yaml
More file actions
144 lines (137 loc) · 3.7 KB
/
Copy pathcompose.yaml
File metadata and controls
144 lines (137 loc) · 3.7 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
# Docker Compose development environment for MapaCultural
# Usage: docker compose up -d
# Access: http://localhost:8080
# MailPit UI: http://localhost:8025
services:
mapas:
build:
context: .
dockerfile: Dockerfile
target: development
args:
COMPOSER_ARGS: "" # include dev dependencies
container_name: mapas-dev-mapas
depends_on:
postgres:
condition: service_healthy
environment:
DB_HOST: postgres
DB_PORT: 5432
DB_NAME: mapas
DB_USER: mapas
DB_PASS: mapas-dev
MAILER_TRANSPORT: "smtp://mailpit:1025"
MAILER_FROM: "dev@mapas.local"
BUILD_ASSETS: "0"
CI: "true"
BASE_URL: "http://localhost:8080/"
APP_DEBUG: "true"
DISABLE_SUBSITES: "true"
PENDING_PCACHE_RECREATION_INTERVAL: "5"
JOBS_INTERVAL: "5"
NUM_PROCESSES: "2"
MC_UPDATES_PROCESSES: "2"
GOOGLE_RECAPTCHA_SITEKEY: "6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI"
GOOGLE_RECAPTCHA_SECRET: "6LeIxAcTAAAAAGG-vFI1TnRWxMZNFuojJ4WifJWe"
REDIRECT_404_ASSETS_TO: ""
volumes:
- ./dev/docker/php.ini:/usr/local/etc/php/php.ini:ro
- ./docker/entrypoint.sh:/entrypoint.sh:ro
- ./docker/jobs-cron.sh:/jobs-cron.sh:ro
- ./docker/recreate-pending-pcache-cron.sh:/recreate-pending-pcache-cron.sh:ro
- ./src:/var/www/src:cached
- ./config:/var/www/config:cached
- ./public:/var/www/html:cached
- ./scripts:/var/www/scripts:cached
- ./composer.json:/var/www/composer.json:cached
- ./composer.lock:/var/www/composer.lock:cached
- mapas-var:/var/www/var
- mapas-assets:/var/www/html/assets
- mapas-files:/var/www/html/files
- mapas-private:/var/www/var/private-files
- ./dev/config.d:/var/www/config/config.d:ro
- ./tests/:/var/www/tests
- ./phpunit.xml:/var/www/phpunit.xml:ro
networks:
- mapas-dev
healthcheck:
test: ["CMD", "test", "-f", "/mapas-ready"]
interval: 10s
timeout: 5s
retries: 5
start_period: 30s
postgres:
image: postgis/postgis:14-3.4
container_name: mapas-dev-postgres
environment:
POSTGRES_DB: mapas
POSTGRES_USER: mapas
POSTGRES_PASSWORD: mapas-dev
ports:
- "5432:5432"
volumes:
- postgres-data:/var/lib/postgresql/data
- ./dev/db:/docker-entrypoint-initdb.d:ro
networks:
- mapas-dev
healthcheck:
test: ["CMD-SHELL", "pg_isready -U mapas -d mapas"]
interval: 10s
timeout: 5s
retries: 5
mailpit:
image: axllent/mailpit:v1.18
container_name: mapas-dev-mailpit
ports:
- "1025:1025"
- "8025:8025"
networks:
- mapas-dev
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
target: development
container_name: mapas-dev-frontend
depends_on:
mapas:
condition: service_healthy
environment:
MAPAS_API_URL: "http://mapas:80"
PHP_API_URL: "http://mapas:80"
volumes:
- ./frontend/src:/app/src:cached
- ./frontend/public:/app/public:cached
- ./frontend/styles:/app/styles:cached
- frontend-data:/app/data
networks:
- mapas-dev
caddy:
image: caddy:2
container_name: mapas-dev-caddy
depends_on:
mapas:
condition: service_healthy
frontend:
condition: service_started
ports:
- "80:80"
- "8443:8443/tcp"
volumes:
- ./Caddyfile:/etc/caddy/Caddyfile:ro
- caddy_data:/data
- caddy_config:/config
networks:
- mapas-dev
volumes:
postgres-data:
mapas-var:
mapas-assets:
mapas-files:
mapas-private:
caddy_data:
caddy_config:
frontend-data:
networks:
mapas-dev:
driver: bridge