Switch from localtunnel to cloudflared, fix static file serving
- Replace localtunnel with cloudflared (no interstitial password page) - Wait for "Registered tunnel connection" before starting bot - Serve index.html at / instead of directory listing - Remove localtunnel npm package build from flake.nix Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
f025e5fd19
commit
f2cfe72d63
3 changed files with 20 additions and 22 deletions
|
|
@ -202,7 +202,12 @@ def create_app() -> web.Application:
|
|||
# Serve the webapp/ folder
|
||||
import pathlib
|
||||
webapp_dir = pathlib.Path(__file__).parent / "webapp"
|
||||
app.router.add_static("/", webapp_dir, show_index=True)
|
||||
|
||||
async def index_handler(request):
|
||||
return web.FileResponse(webapp_dir / "index.html")
|
||||
|
||||
app.router.add_get("/", index_handler)
|
||||
app.router.add_static("/", webapp_dir)
|
||||
|
||||
return app
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue