A small Express web UI that lists running processes (via systeminformation) and lets you stop them, sorted by total memory usage.
Running in DEMO_MODE — the process list above is simulated, "Stop" is a no-op. See "Deploying a live demo" below to run it live somewhere instead of just viewing this screenshot.
npm install
npm start
Open http://localhost:5000/task-manager. This mode lists and can stop real processes on the machine it runs on — only run it on your own machine, never expose it to the public internet in this mode.
Set DEMO_MODE=true to serve a simulated, fixed process list where "Stop" is a no-op. This is the mode used for any publicly-hosted deployment:
DEMO_MODE=true npm start
(On Windows PowerShell: $env:DEMO_MODE="true"; npm start)
In DEMO_MODE, this app never touches real processes or calls the Windows-only taskkill command, so it can run on any platform (including Render's Linux containers) even though the underlying tool is Windows-specific.
- Push this repo to GitHub, then create a free account at render.com.
- New → Web Service → connect this GitHub repo.
- Build command:
npm install. Start command:node TaskManager.js. - Add an environment variable
DEMO_MODE=true. Render setsPORTautomatically, which the app already reads. - Deploy, then visit
https://<your-service>.onrender.com/task-manager.
processNamevalues are now validated against^[A-Za-z0-9_\-. ]+$before use, and process termination usesexecFile('taskkill', [...])instead of a shell-interpolatedexec()string — the previous version was vulnerable to command injection via the/stop-processesrequest body.- There is no authentication on either route. Only run "real mode" on a trusted local machine/network — never deploy real mode to a public server. Public deployments should always use
DEMO_MODE=true. - The listen port now respects
process.env.PORT(falls back to 5000), since most hosting platforms assign the port dynamically.
MIT — see LICENSE.
