-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
144 lines (127 loc) · 3.86 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
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
version: '3.8'
networks:
stack: {}
volumes:
afetcan_db_postgres_data:
services:
afetcan_db:
image: postgis/postgis:15-master
restart: always
volumes:
- ./docker/pg-init-scripts:/docker-entrypoint-initdb.d
- afetcan_db_postgres_data:/var/lib/postgresql/data
ports:
- "5432:5432"
environment:
POSTGRES_USER: '${POSTGRES_USER}'
POSTGRES_PASSWORD: '${POSTGRES_PASSWORD}'
POSTGRES_MULTIPLE_DATABASES: '${POSTGRES_DBS}'
extra_hosts:
- "host.docker.internal:host-gateway"
networks:
- 'stack'
healthcheck:
test: pg_isready -q -d ${POSTGRES_DBS} -U ${POSTGRES_USER}
interval: 5s
timeout: 5s
retries: 6
afetcan_cache:
container_name: afetcan_cache
image: redis:7
networks:
- stack
afetcan_redis:
image: redis:7.0.9-alpine
networks:
- 'stack'
ports:
- "6379:6379"
command: redis-server --save 20 1 --loglevel warning --requirepass redispass
restart: always
afetcan_directus:
container_name: afetcan_directus
image: directus/directus:9.23.1
ports:
- 8055:8055
volumes:
# By default, uploads are stored in /directus/uploads
# Always make sure your volumes matches the storage root when using
# local driver
# - ./afetcan/uploads:/directus/uploads
# Make sure to also mount the volume when using SQLite
# - ./database:/directus/database
# If you want to load extensions from the host
- ./afetcan/directus/extensions:/directus/extensions
networks:
- stack
depends_on:
- afetcan_cache
- afetcan_db
environment:
KEY: '255d861b-5ea1-5996-9aa3-922530ec40b1'
SECRET: '6116487b-cda1-52c2-b5b5-c8022c45e263'
DB_CLIENT: 'pg'
DB_HOST: 'afetcan_db'
DB_PORT: '5432'
DB_DATABASE: 'postgres'
DB_SCHEMA: 'directus'
DB_CUSTOM_SCHEMA: 'directus'
DB_USER: '${POSTGRES_USER}'
DB_PASSWORD: '${POSTGRES_PASSWORD}'
DB_SEARCH_PATH: "array:directus,auth,public"
CACHE_ENABLED: 'true'
CACHE_STORE: 'redis'
CACHE_REDIS: 'redis://afetcan_cache:6379'
ADMIN_EMAIL: 'admin@example.com'
ADMIN_PASSWORD: 'd1r3ctu5'
# supertokens:
# image: registry.supertokens.io/supertokens/supertokens-postgresql:4.3
# depends_on:
# db:
# condition: service_healthy
# ports:
# - 3567:3567
# environment:
# POSTGRESQL_USER: '${POSTGRES_USER}'
# POSTGRESQL_PASSWORD: '${POSTGRES_PASSWORD}'
# POSTGRESQL_DATABASE_NAME: '${SUPERTOKENS_POSTGRES_DB}'
# POSTGRESQL_TABLE_SCHEMA: 'auth'
# # POSTGRESQL_TABLE_NAMES_PREFIX: 'supertokens'
# POSTGRESQL_HOST: db
# POSTGRESQL_PORT: 5432
# API_KEYS: '${SUPERTOKENS_API_KEY}'
# restart: always
# healthcheck:
# test: >
# bash -c 'exec 3<>/dev/tcp/127.0.0.1/3567 && echo -e "GET /hello HTTP/1.1\r\nhost: 127.0.0.1:3567\r\nConnection: close\r\n\r\n" >&3 && cat <&3 | grep "Hello"'
# interval: 10s
# timeout: 5s
# retries: 5
# networks:
# - 'stack'
# clickhouse:
# image: clickhouse/clickhouse-server:23.1.2-alpine
# volumes:
# - ./.afetcan/clickhouse/logs:/var/log/clickhouse-server
# - ./.afetcan/clickhouse/db:/var/lib/clickhouse
# - ./docker/configs/clickhouse:/etc/clickhouse-server/conf.d
# # - ./docker/clickhouse/init-defaults.sh:/docker-entrypoint-initdb.d/init-defaults.sh:ro
# healthcheck:
# test: ['CMD', 'wget', '--spider', '-q', 'localhost:8123/ping']
# interval: 5s
# timeout: 5s
# retries: 6
# start_period: 10s
# environment:
# CLICKHOUSE_DB: public
# CLICKHOUSE_USER: test
# CLICKHOUSE_PASSWORD: test
# ports:
# - 8123:8123
# networks:
# - 'stack'
# cache:
# container_name: cache
# image: redis:7
# networks:
# - stack