-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yaml
99 lines (98 loc) · 3.06 KB
/
docker-compose.yaml
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
# SPDX-FileCopyrightText: 2024 JWP Consulting GK
#
# SPDX-License-Identifier: AGPL-3.0-or-later
---
name: projectify-compose
volumes:
postgres-data:
keydb-data:
services:
web:
image: projectify-revproxy:latest
restart: always
ports:
- "5000:80"
environment:
HOST: "localhost"
PORT: "80"
FRONTEND_HOST: frontend
FRONTEND_PORT: "5001"
BACKEND_HOST: backend
BACKEND_PORT: 5002
depends_on:
- frontend
- backend
frontend:
image: projectify-frontend-node:latest
restart: always
environment:
SVELTE_KIT_PORT: 5001
backend:
image: projectify-backend:latest
restart: always
environment: &backend-env
SECRET_KEY: do-not-use
# Networking
PORT: "5002"
ALLOWED_HOSTS: "localhost"
# Settings
DJANGO_SETTINGS_MODULE: projectify.settings.production
DJANGO_CONFIGURATION: Production
# Database
DATABASE_URL: postgres://projectify:projectify@postgres:5432/projectify
REDIS_TLS_URL: redis://keydb:6379/0
# Frontend
FRONTEND_URL: http://localhost:5000
# Stripe
STRIPE_PUBLISHABLE_KEY: pk_test_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
STRIPE_SECRET_KEY: sk_test_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
STRIPE_PRICE_OBJECT: price_XXXXXXXXXXXXXXXXXXXXXXXX
STRIPE_ENDPOINT_SECRET: whsec_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
# Mailgun
MAILGUN_API_KEY: XXXX
MAILGUN_DOMAIN: localhost
depends_on:
- keydb
- postgres
- worker
ports:
migrate_backend:
image: projectify-backend:latest
restart: always
environment: *backend-env
command: projectify-manage migrate
depends_on:
- postgres
worker:
image: projectify-celery:latest
restart: always
environment: *backend-env
depends_on:
- keydb
- postgres
keydb:
image: docker.io/eqalpha/keydb:latest
restart: always
volumes:
- keydb-data:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 1s
timeout: 3s
retries: 30
postgres:
image: docker.io/postgres:15
restart: always
shm_size: 128mb
volumes:
- postgres-data:/var/lib/postgresql/data
environment:
POSTGRES_DB: projectify
POSTGRES_USER: projectify
POSTGRES_PASSWORD: projectify
PGDATA: /var/lib/postgresql/data/pgdata
healthcheck:
test: ["CMD-SHELL", "pg_isready -U projectify"]
interval: 30s
timeout: 30s
retries: 3