Remote Debugging with SSH and VS Code
A Node.js process running on Render can be debugged from a local VS Code instance by starting it with `node --inspect=9229` and forwarding the debug port over an SSH tunnel (`ssh -N -L 9229:localhost:9229`). This avoids exposing the inspector port publicly. VS Code attaches through a launch.json "Attach to Remote Program" config with remoteRoot set to the deploy directory. Once attached, breakpoints, variable inspection, call stacks and break-on-exception all work as they do locally, which helps with bugs that only reproduce in the production Linux environment. The Flame Chart Visualizer extension adds live CPU and memory profiling over the same connection.
Related posts
- Let’s Debug a Node.js Application
Heroku Engineering mediumAdeptNode.js debugging options range from structured logging to post-mortem analysis. Use leveled loggers like Pino or Winston instead of console.log, set breakpoints and take heap snapshots via `node --inspect-brk` with Chrome DevTools, an IDE, or ndb (which supports edit-in-place), and analyze native crashes with llnode on core dumps produced by `process.abort`. The debug module filters namespaced log output through the DEBUG environment variable, while trace and clarify improve async stack traces locally but should not run in production.
- Host a Dev Environment on Render with VS Code and Tailscale
Render mediumAdept
A self-hosted cloud dev environment can run on Render as a private service, reached over a Tailscale subnet router and edited with VS Code's Remote-SSH extension. code-server works and installs as a PWA, but it lacks some extensions. OpenSSH fails in Render's unprivileged containers because privilege separation needs CAP_SYS_CHROOT, so dropbear serves SSH instead, with SSH agent forwarding for GitHub authentication. A persistent disk mounted at /home keeps repos, caches and the VS Code binaries across deploys, and a start script recreates authorized_keys at runtime so the mount doesn't overwrite it.
- Use One-Click Deploys for Secure Online VS Code
Render mediumAdept
OpenVSCode Server can be deployed on Render by forking Gitpod's repo, adding a minimal Dockerfile that pulls the published image, and defining a persistent disk mount in a render.yaml Blueprint. Once render.yaml exists, a single line of markdown in the README creates a Deploy to Render button for one-click deploys. Securing the browser IDE means adding OAuth2-Proxy in the same Blueprint, with `sync: false` keys so users enter their own secrets in the dashboard at deploy time rather than committing them.
- MCP Horror Stories: The Drive-By Localhost Breach
Docker mediumAdeptCVE-2025-49596 (CVSS 9.4) let any website achieve remote code execution on developer machines running MCP Inspector below 0.14.1. The Inspector's Node.js proxy listened on 0.0.0.0:6277 with no authentication and accepted requests from any origin. Malicious JavaScript could send no-cors GET requests to its /sse endpoint with transportType=stdio and arbitrary command arguments, and because browsers treat 0.0.0.0 like localhost (the "0.0.0.0-day" flaw), those requests could spawn processes that read SSH keys, dump environment variables or clone private repos. The fix is upgrading to 0.14.1+, and Docker pitches running its MCP Gateway with stdio transport so no HTTP endpoint is exposed to browsers at all.
- The Debugger is Here
Zed mediumAdeptZed now ships a native debugger built on the Debug Adapter Protocol, with out-of-the-box support for Rust, C/C++, JavaScript, Go and Python. "Locators" turn build tasks such as Cargo runs into debug configurations automatically. Internally it uses a two-layer design: a data layer talks to debug adapters, caches responses by request arguments, lazily fetches and invalidates stale state, and a UI layer queries only what it renders, which sets up future collaborative debugging. Extensions can plug in any of the 70+ DAP implementations, and inline variable values come from Tree-sitter scope queries rather than the LSP inline-values request.