forked from deepgram-starters/flask-live-transcription
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathfly.toml
More file actions
43 lines (36 loc) · 1.25 KB
/
Copy pathfly.toml
File metadata and controls
43 lines (36 loc) · 1.25 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
# fly.toml app configuration file for deepgram-python-stt
# Note: SocketIO requires sticky sessions for multi-machine deployments.
# With min_machines_running = 1 and auto_stop_machines = false, a single machine
# handles all connections, avoiding the need for Redis-backed session storage.
# If you scale beyond 1 machine, add sticky sessions via fly.io HTTP service options.
app = 'deepgram-python-stt'
primary_region = 'iad'
[build]
[env]
PORT = "8080"
# Assert the API token gate is on. If APP_ACCESS_TOKEN is not set as a fly
# secret the app refuses to boot, so a forgotten secret fails the deploy
# loudly instead of quietly serving an open API that spends the Deepgram key.
REQUIRE_AUTH = "true"
[http_service]
internal_port = 8080
# force_https required so browsers allow microphone access (getUserMedia needs HTTPS)
force_https = true
# Keep alive to avoid cold starts during demos
auto_stop_machines = false
auto_start_machines = true
min_machines_running = 1
[http_service.concurrency]
type = "connections"
hard_limit = 50
soft_limit = 25
[[http_service.checks]]
grace_period = "10s"
interval = "15s"
method = "GET"
path = "/"
timeout = "5s"
[[vm]]
memory = '512mb'
cpu_kind = 'shared'
cpus = 1