Skip to content

[Feature Request] Share a locally running app on a public URL with app.run(tunnel=True) #4029

Description

@ndrezn

Sharing an app that runs locally (with a teammate, on a phone, for a quick demo) currently means deploying it or setting up ngrok or a similar tool yourself.

Proposal: add a tunnel option to app.run (and a DASH_TUNNEL env var) that opens a Cloudflare quick tunnel and logs a public trycloudflare.com URL next to the local one. Quick tunnels need no account or login.

Suggested implementation: follow LangChain's --tunnel flag for langgraph dev, which does the same thing with a Cloudflare quick tunnel.

Why Cloudflare and not ngrok: ngrok needs a free account and an authtoken before it will start a tunnel, and has not allowed anonymous tunnels since 2023. Cloudflare quick tunnels are the mainstream option that works with no signup, which is also why LangChain uses them. ngrok's free tier does give one fixed domain (quick tunnel URLs change on every start), so it could be added later as an option for people who already have a token.

For Dash:

  • Use cloudflared from the PATH, or download it once if missing.
  • The URL stays the same across hot reloads.
  • For development only. Anyone with the URL can reach the app, so it should warn when debug is on.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions