-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.yaml
More file actions
101 lines (96 loc) · 3.04 KB
/
Copy pathapp.yaml
File metadata and controls
101 lines (96 loc) · 3.04 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
# DigitalOcean App Platform spec — one-click deploy.
#
# Click the badge in the README, or run:
# doctl apps create --spec .do/app.yaml
#
# After the app comes up, mint your first bearer token from the App console
# or via doctl:
# doctl apps list # find your app id
# doctl apps exec <app-id> server \
# -- ./flashback token mint --user=admin --name=initial
#
# The MCP URL is then https://<app>.ondigitalocean.app/mcp with the bearer
# pasted into your Claude Desktop / Cursor / Claude Code config.
name: flashback
region: nyc
# Public-facing services. Routing is longest-prefix-match — `/mcp` wins over `/`.
services:
# REST API. Embeddings + entity extraction run in-process (fastembed-rs
# + rule-based extractor) — no Python sidecar in Phase 2.
# AUTO_MIGRATE=1 so the first boot creates the schema.
- name: server
dockerfile_path: Dockerfile
source_dir: /
http_port: 8080
instance_count: 1
# The fastembed ONNX model lives in the image (built into the
# /opt/flashback/fastembed-cache path during docker build). 1 GB RAM is
# enough at idle; bump if you switch to a larger embedding model.
instance_size_slug: apps-s-1vcpu-1gb
routes:
- path: /
health_check:
http_path: /health
initial_delay_seconds: 30
period_seconds: 10
timeout_seconds: 5
failure_threshold: 6
envs:
- key: DATABASE_URL
value: ${db.DATABASE_URL}
scope: RUN_AND_BUILD_TIME
- key: HOST
value: "0.0.0.0"
scope: RUN_TIME
- key: PORT
value: "8080"
scope: RUN_TIME
- key: AUTO_MIGRATE
value: "1"
scope: RUN_TIME
- key: FLASHBACK_FASTEMBED_CACHE
value: /opt/flashback/fastembed-cache
scope: RUN_TIME
- key: RUST_LOG
value: flashback=info,tower_http=info
scope: RUN_TIME
# MCP wrapper. Same image as `server` — both binaries are baked in.
# `run_command` overrides the Dockerfile CMD to start the MCP binary.
- name: mcp
dockerfile_path: Dockerfile
source_dir: /
run_command: ./flashback-mcp
http_port: 8082
instance_count: 1
instance_size_slug: apps-s-1vcpu-1gb
routes:
- path: /mcp
health_check:
http_path: /health
initial_delay_seconds: 30
period_seconds: 10
timeout_seconds: 5
failure_threshold: 6
envs:
- key: FLASHBACK_URL
value: http://${server.PRIVATE_DOMAIN}:8080
scope: RUN_TIME
- key: MCP_HOST
value: "0.0.0.0"
scope: RUN_TIME
- key: MCP_PORT
value: "8082"
scope: RUN_TIME
- key: RUST_LOG
value: flashback_mcp=info,tower_http=info
scope: RUN_TIME
# Managed Postgres. The dev tier is cheapest; bump `size` for production.
# pgvector is supported on DO managed Postgres — our migration calls
# CREATE EXTENSION IF NOT EXISTS vector, which DO permits on managed clusters.
databases:
- name: db
engine: PG
version: "16"
production: false
size: db-s-dev-database
num_nodes: 1