-
-
Notifications
You must be signed in to change notification settings - Fork 18
Expand file tree
/
Copy pathfly.toml
More file actions
44 lines (38 loc) · 1.27 KB
/
Copy pathfly.toml
File metadata and controls
44 lines (38 loc) · 1.27 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
# Fly.io deploy config for the three.ws multiplayer server.
#
# After `fly launch --no-deploy` reads this file once, run:
# fly secrets set ALLOWED_ORIGINS=https://three.ws,https://www.three.ws
# # Durable voxel-build storage (block-store.js). Without these, each coin
# # world's build is memory-only and a redeploy wipes it. Same Upstash creds
# # as the Vercel API, but they must be set HERE too — the server runs apart.
# fly secrets set UPSTASH_REDIS_REST_URL=... UPSTASH_REDIS_REST_TOKEN=...
# fly deploy
#
# To scale rooms across machines, bump `min_machines_running` and use
# Fly's autoscaling. Each Colyseus room is single-process — sharding across
# machines is handled by Colyseus's match-making + `@colyseus/redis-presence`
# (add when you cross ~200 concurrent players).
app = "three-ws-multiplayer"
primary_region = "iad"
[build]
dockerfile = "Dockerfile"
[env]
PORT = "2567"
NODE_ENV = "production"
[http_service]
internal_port = 2567
force_https = true
auto_stop_machines = false
auto_start_machines = true
min_machines_running = 1
processes = ["app"]
[[http_service.checks]]
grace_period = "10s"
interval = "30s"
method = "GET"
timeout = "5s"
path = "/health"
[[vm]]
cpu_kind = "shared"
cpus = 1
memory_mb = 256