Skip to main content

What this solves

If your app prints something like:
Serving HTTP on 127.0.0.1 port 8888
and your public URL (e.g. https://<instance-id>-8888.tenants.hivecompute.ai) shows Bad Gateway, it likely means:
  • The app is only available locally (localhost)
  • HTTPS reverse proxy can’t reach it

Step 1 – Start your server (pick one)

If you already have an appIf you just want to browse files
SSH into the instance and launch your app on port 8888 with host 0.0.0.0. Example (Flask): app.run(host="0.0.0.0", port=8888)SSH in and run a one-off file server: python3 -m http.server 8888 --bind 0.0.0.0
Only one process can occupy port 8888. Stop the file server before starting your real app—or give one of them a different port.

Step 2 – Bind to 0.0.0.0, not 127.0.0.1

Visit https://<instance-id>-8888.tenants.hivecompute.ai.
If you switched ports, replace 8888 in both the URL and your app command.

Step 3 – Open the HTTPS URL

Once your app is running and listening on the correct interface and port, go to:
https://<instance-id>-8888.tenants.hivecompute.ai
Make sure your firewall or instance settings don’t block port 8888.
If you still see “Bad Gateway”:
  • Double-check your app is running
  • Use curl http://localhost:8888 from inside the instance to test
  • Restart your app if needed

Alternative: Use SSH port forwarding

If HTTPS still doesn’t work or you prefer to access it directly:
ssh -L 8888:localhost:8888 ubuntu@<instance-id>.ssh.hivecompute.ai
Then open http://localhost:8888 on your Windows or Mac browser
I