File tree Expand file tree Collapse file tree 2 files changed +24
-9
lines changed Expand file tree Collapse file tree 2 files changed +24
-9
lines changed Original file line number Diff line number Diff line change @@ -437,6 +437,23 @@ def fix_uploads_uniqueness():
437437
438438#########################################################
439439
440+ @app .route ("/healthz" )
441+ def healthz ():
442+ # Must be super fast and always 200 so Fly can mark the machine healthy
443+ return "ok" , 200
444+
445+ #########################################################
446+
447+ @app .route ("/diag/routes" )
448+ def diag_routes ():
449+ # Lets you confirm which routes are actually registered in prod
450+ if not session .get ("admin" ):
451+ abort (403 )
452+ rules = sorted ([str (r ) for r in app .url_map .iter_rules ()])
453+ return jsonify ({"routes" : rules })
454+
455+ #########################################################
456+
440457# -- View and import (admin only) --
441458@app .route ('/materials/<property_name>/<tab>' , methods = ['GET' , 'POST' ])
442459def property_detail (property_name , tab ):
Original file line number Diff line number Diff line change 1- # fly.toml app configuration file generated for patterns-matter on 2025-07-28T11:37:29+02:00
1+ # fly.toml app configuration file for patterns-matter on 2025-07-28T11:37:29+02:00
22#
33# See https://fly.io/docs/reference/configuration/ for information about how to use this file.
4- #
54
65app = ' patterns-matter'
76primary_region = ' ams'
87
9- [checks ]
10- [checks .web ]
11- grace_period = " 10s"
12- interval = " 15s"
13- method = " get"
14- path = " /"
8+
9+ [[http_service .checks ]]
10+ method = " GET"
11+ path = " /healthz"
12+ interval = " 10s"
1513 timeout = " 2s"
16- type = " http "
14+ grace_period = " 30s "
1715
1816
1917[http_service ]
You can’t perform that action at this time.
0 commit comments