-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcoolify.yml
More file actions
63 lines (58 loc) · 1.77 KB
/
coolify.yml
File metadata and controls
63 lines (58 loc) · 1.77 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
# SnapLink - Coolify Deployment Configuration
# This file is for reference. Actual configuration happens in Coolify UI.
version: '3'
services:
# PostgreSQL Database
postgres:
image: postgres:16-alpine
environment:
POSTGRES_DB: snaplink
POSTGRES_USER: snaplink
POSTGRES_PASSWORD: ${DB_PASSWORD}
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ['CMD-SHELL', 'pg_isready -U snaplink']
interval: 10s
timeout: 5s
retries: 5
# SnapLink Application
snaplink:
build:
context: .
dockerfile: Dockerfile
depends_on:
postgres:
condition: service_healthy
environment:
DATABASE_URL: postgresql://snaplink:${DB_PASSWORD}@postgres:5432/snaplink
NEXTAUTH_SECRET: ${NEXTAUTH_SECRET}
NEXTAUTH_URL: ${NEXTAUTH_URL}
GITHUB_ID: ${GITHUB_ID}
GITHUB_SECRET: ${GITHUB_SECRET}
SENTRY_DSN: ${SENTRY_DSN}
SENTRY_AUTH_TOKEN: ${SENTRY_AUTH_TOKEN}
NODE_ENV: production
NEXT_PUBLIC_API_URL: ${NEXT_PUBLIC_API_URL}
ports:
- '3000:3000'
healthcheck:
test: ['CMD', 'curl', '-f', 'http://localhost:3000/api/health']
interval: 30s
timeout: 5s
retries: 3
start_period: 10s
restart: unless-stopped
volumes:
postgres_data:
# Coolify Configuration Notes:
# 1. Deploy from GitHub: ibuzzardo/snaplink
# 2. Select branch: main (auto-deploy on push)
# 3. Build command: npm run build
# 4. Start command: npm start
# 5. Set all environment variables listed above
# 6. Enable health check: /api/health (should return 200)
# 7. Set container name: snaplink-app
# 8. Expose port: 3000
# 9. Configure domain: snaplink.72.60.194.93.nip.io (or custom domain)
# 10. Enable SSL/TLS via Let's Encrypt (automatic in Coolify)