-
-
Notifications
You must be signed in to change notification settings - Fork 66
/
Copy pathdocker-compose.yml
113 lines (111 loc) · 3.47 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
# NOTE: If you're selfhosting, you'll find it much easier (and more performant) to use the proper selfhosted
# dockerfile that exists here: https://github.com/julianpoy/recipesage-selfhost
services:
proxy:
image: nginx
volumes:
- ./nginx/default.conf:/etc/nginx/conf.d/default.conf
ports:
- "80:80"
command: nginx -g 'daemon off;'
depends_on:
- frontend
- backend
- pushpin
frontend:
build:
context: .
dockerfile: ./Dockerfile
volumes:
- ./packages:/app/packages
ports:
- "8100:8100"
command: npx nx start frontend
backend:
depends_on:
- postgres
- pushpin
- browserless
build:
context: .
dockerfile: ./Dockerfile
volumes:
- ./packages:/app/packages
- ./.credentials:/app/.credentials
ports:
- "3000:3000"
command: ./scripts/watchandrun.sh 'node node_modules/ts-node/dist/bin.js --swc --project packages/backend/tsconfig.json packages/backend/src/bin/www' ./packages/backend ./packages/trpc ./packages/util ./packages/express ./packages/prisma
environment:
- AWS_REGION=us-west-2
- AWS_BUCKET=chefbook-dev
- FIRESTORE_BUCKET=
- STORAGE_TYPE=s3 #POSSIBLE VALUES: s3, firebase, filesystem
- NODE_ENV=development
- VERBOSE=false
- VERSION=development
- POSTGRES_DB=recipesage_dev
- POSTGRES_USER=recipesage_dev
- POSTGRES_PASSWORD=recipesage_dev
- POSTGRES_PORT=5432
- POSTGRES_HOST=postgres
- POSTGRES_SSL=false
- POSTGRES_LOGGING=true
- DATABASE_URL=postgresql://recipesage_dev:recipesage_dev@postgres:5432/recipesage_dev
- GCM_KEYPAIR
- SENTRY_SAMPLE_RATE=0
- GRIP_URL=http://pushpin:5561/
- GRIP_KEY=changeme
- SEARCH_PROVIDER=typesense
- 'TYPESENSE_NODES=[{"host": "typesense", "port": 8108, "protocol": "http"}]'
- TYPESENSE_API_KEY=recipesage_dev
- BROWSERLESS_HOST=browserless
- BROWSERLESS_PORT=3000
- BROWSERLESS_TOKEN=recipesage_dev
- INGREDIENT_INSTRUCTION_CLASSIFIER_URL=http://ingredient-instruction-classifier:3000/
env_file:
- ./.env
typesense:
image: typesense/typesense:0.24.1
volumes:
- typesense-data:/data
command: "--data-dir /data --api-key=recipesage_dev --enable-cors"
pushpin:
image: julianpoy/pushpin:2023-09-17
entrypoint: /bin/sh -c
command:
[
'sed -i "s/sig_key=changeme/sig_key=$$GRIP_KEY/" /etc/pushpin/pushpin.conf && echo "* $${TARGET},over_http" > /etc/pushpin/routes && pushpin --merge-output',
]
environment:
- GRIP_KEY=changeme
- TARGET=backend:3000
postgres:
image: postgres:16.1
command:
- "postgres"
- "-c"
- "wal_level=logical"
ports:
- 5432:5432
environment:
- POSTGRES_DB=recipesage_dev
- POSTGRES_USER=recipesage_dev
- POSTGRES_PASSWORD=recipesage_dev
browserless:
image: browserless/chrome:1.61.0-puppeteer-21.4.1
environment:
- MAX_CONCURRENT_SESSIONS=3
- MAX_QUEUE_LENGTH=10
- DEFAULT_BLOCK_ADS=true
- DEFAULT_LAUNCH_ARGS=["--disable-web-security"]
- WORKSPACE_DELETE_EXPIRED=true
- WORKSPACE_EXPIRE_DAYS=1
- EXIT_ON_HEALTH_FAILURE=true
- PREBOOT_CHROME=true
- KEEP_ALIVE=true
- FUNCTION_ENABLE_INCOGNITO_MODE=true
- TOKEN=recipesage_dev
ingredient-instruction-classifier:
image: julianpoy/ingredient-instruction-classifier:1.4.9
volumes:
typesense-data: