Skip to content

nschllr/docker_logs_webviewer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Docker Webview

Local web UI for inspecting Docker containers and tailing logs from the selected container.

Features

  • Lists containers in separate Running and Stopped tabs
  • Filters both tabs by image name substring
  • Streams a recent log backlog plus live updates for running containers
  • Shows saved Docker logs for stopped containers, including containers opened after they already stopped
  • Preserves the last viewed logs when the selected container stops
  • Keeps the log pane scroll position unless you are already near the bottom

Requirements

  • Node.js 24+
  • Docker running on the same machine
  • Access to the local Docker socket at /var/run/docker.sock

If docker ps fails with a permission error, fix Docker socket access for the user running the app before starting this project.

Install

npm install

Development

Run both the backend and the Vite frontend:

npm run dev

This starts:

  • UI: http://127.0.0.1:5173
  • API: http://127.0.0.1:3001

The Vite dev server proxies /api requests to the backend.

Remote browser access during development

If you want to open the UI from another machine, bind both processes to all interfaces:

HOST=0.0.0.0 npm run dev:server
npm run dev:ui -- --host 0.0.0.0

Then open:

http://YOUR_SERVER_IP:5173

Port 3001 is the backend API, not the UI.

Single-port run

To serve the built frontend from the Node backend on one port:

npm run build
HOST=0.0.0.0 npm start

Then open:

http://YOUR_SERVER_IP:3001

Scripts

  • npm run dev - start backend and frontend for local development
  • npm run dev:server - start only the Node backend
  • npm run dev:ui - start only the Vite frontend
  • npm run build - build the frontend into dist/
  • npm start - run the backend and serve the built frontend if present
  • npm test - run backend unit tests

Notes

  • The backend currently talks to Docker through the hard-coded default socket path /var/run/docker.sock.
  • The backend default bind host is 127.0.0.1, unless overridden with HOST.
  • The frontend filter matches image names, not container names, across both tabs.
  • Removing a stopped container from the sidebar only clears it from the UI; it does not delete anything in Docker.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors