dev-code-proxy

Reference

Commands

Every command prints what to do next when something is off. dcp <command> --help lists its flags; -v prints the version.

Both halves

CommandWhat it does
dcp doctorCheck Tailscale, each sharing provider and local HTTPS; each ✗ with the command that fixes it, and the dashboard link; exit 1 when one fails
dcp ls [pattern] [--json]One line per app and link: NAME PORT PROVIDER STATE URL, the provider local, tailscale or cloudflare, the state up, online, not shared or exited; the pattern keeps apps whose name, folder or URL has it
dcp url <app> [--local|--tailscale|--cloudflare]Just the URL (curl $(dcp url api --cloudflare)); without a flag the best one online (Cloudflare, Tailscale, local); exit 1 when it is not online yet
dcp open <app> [--local|--tailscale|--cloudflare]Open that URL in the browser
dcp updateUpdate to the latest release, the way dcp was installed (brew, npm or the binary itself, checksum-verified)
dcp stats [--since 24h] [--json]How the local proxy runs: health, updates, and requests, failures and p50/p95/p99 per name (Logs and stats)
dcp logs [-n 40] [-f] [--json]The local proxy's events: starts, live updates, rollbacks, failed or slow requests
dcp uninstall [--yes] [--all]Remove everything dcp set up: the Tailscale entry it created, the boot service, the CA and ~/.dcp; --all also the config and a standalone binary

Local HTTPS names

CommandWhat it does
(nothing)Every dev server found gets https://<name>.localhost: its folder's name, or name from its project config (Local HTTPS names)
dcp runRun the app in this folder from package.json or .dcp.json "dcp": { "name", "script" }
dcp run <name> -- '<command>'Run any command at https://<name>.localhost; one quoted string runs through the shell, after PORT and HOST are set
dcp run --forceTake a name over from a run in another terminal
dcp restartRestart the local HTTPS proxy: a fresh copy takes over live, no sudo, no dropped request (Restart or reload)
dcp reloadRead the settings again and look for dev servers now
dcp stop <name|port>Stop the app behind a name, or what listens on a port: SIGTERM (Windows: taskkill /T), like Ctrl-C; asks first. --force ends it and every process it started at once (a hung app), --pid <n> stops one process, --yes skips the question (Stop an app)
dcp configure --discover=falseStop finding dev servers; only dcp run names remain
dcp configure --catch-allAnswer every .localhost name: one nothing serves shows what runs (default off: no answer)
dcp configure --dashboard=falseTurn https://dcp.localhost off (default on)
https://dcp.localhostThe dashboard: what runs, requests and latency per name, CPU and memory and a Stop button per app, the proxy's state (JSON at /api/status)
dcp service installOnce per machine (your password once): the proxy from boot, its CA trusted; it updates itself afterwards. Safe to repeat
dcp service statusThree ✓/✗ lines; exit 1 when one is off
dcp service uninstallStop and remove the boot service
dcp trustTrust the local CA only
dcp proxy [--port n]The proxy in the foreground (what the boot service runs)
CommandWhat it does
dcp status [--json]Each provider: online, not online with the problem, its fix and a help link, or off with the command that turns it on; exit 1 when a provider that is on is not online (Share online)
dcp check [--json]Open every online link from the outside: DNS via 1.1.1.1, the TLS certificate (issuer, expiry), the HTTP status
dcp tailscale on [--tailnet|--public] [--https-port 443]Share through Tailscale: Funnel (--public, the default) or Serve (--tailnet)
dcp tailscale offStop sharing through Tailscale (dcp's Funnel or Serve entry is removed)
dcp cloudflare on --zone example.com [--env-file .env | --token-stdin] [--host '{app}-{machine}']Share through a Cloudflare Tunnel: checks the credentials, saves them, waits for the tunnel, a DNS record per app and the connector, then checks each link (Cloudflare)
dcp cloudflare syncSync now: the tunnel, a DNS record per app, the connector (otherwise every 5 minutes and when the apps change)
dcp cloudflare off [--purge] [--forget]Stop the connector; --purge also deletes the tunnel and the DNS records dcp made, --forget the saved credentials
dcpWith the local HTTPS proxy running: what dcp status prints (sharing is on by default)
dcp start [flags]The same; without the boot service, share Tailscale from this terminal (Ctrl-C ends it, --bg detaches)
dcp configure [flags]Save flags as defaults in ~/.dcp/config.json

start flags

dcp start shares from the terminal only without the boot service. Defaults come from your config file (see Configuration).

FlagDefaultMeaning
--ports <lo-hi|port>3000-6000Port range or a single port to scan
--alloffInclude all listeners, not just web runtimes
--runtimes <list>all knownRestrict to specific runtimes, e.g. node,bun,python
--dockeroffAlso discover Docker containers via the local Docker API (read-only)
--privateconfig privateThis terminal share through Tailscale Serve (default: Funnel)
--bind <addr>127.0.0.1Listen address; 0.0.0.0 to reach from containers/LAN
--port <n>18443Local proxy HTTP port (never a Funnel port: Tailscale.app's Serve binds that port on every address)
--interval <sec>20Re-scan period
--https-port <n>config httpsPortThis terminal share's HTTPS port (Funnel: 443/8443/10000)
--deregister-cycles <n>5Missing scans before a gone service is removed
--forward-hostoffForward the public host to apps via X-Forwarded-Host/Proto (default: local)
--match-separatorsonRoute /a-b/ and /a_b/ alike; --match-separators=false for exact-dash
--accept-dns <bool>unsetOptionally tailscale set --accept-dns on start; false lets a tailnet host resolve the public funnel name (persists)
--bgoffRun detached (logs → ./dcp.log)
--proxy-onlyoffRun the proxy only; print the tailscale command
--log-requestsonLog each proxied request
--quietoffDisable per-request logging

Startup output

On start, dcp prints the effective parameters and logs discoveries:

Using config: /Users/me/.dcp/config.json
  ports=3000-6000  mode=public (Funnel)  proxy=127.0.0.1:18443  https=443
  interval=20s  runtimes=default (…)  deregister-after=5 scans  log-requests=true
  host=local (apps see localhost)

2026/05/31 02:05:48 discovered web   node   :4983  pid 15588  ~/work/help-ai/apps/web
2026/05/31 02:05:49 200 GET    /web/ → 127.0.0.1:4983 (6ms)

Request logs are colorized by status on a terminal (set NO_COLOR to disable).

One-liners

dcp ls                         # every app with each link
dcp ls api | grep cloudflare   # one app's Cloudflare link
dcp tailscale off; dcp cloudflare off   # take every link down
dcp --ports 4000               # scan a single port
dcp --interval 5               # faster pickup of new servers
dcp --proxy-only               # local proxy only; print the tailscale command
dcp --bg                       # run detached; logs → ./dcp.log
dcp --forward-host             # send the public host to apps
dcp --match-separators=false   # exact-dash routing (default treats - and _ alike)