Sign inSign up

penrithbeacon/wcp-widget-docker

By penrithbeacon

•Updated 4 months ago

Penrith Beacon WCP — Docker containers, images, and Docker Hub browser for local and NAS hosts.

Image
0

1.1K

penrithbeacon/wcp-widget-docker repository overview

⁠WCP Widget: Docker

A Widget Context Protocol (WCP)⁠ widget that brings full Docker management into any WCP-compatible dashboard. Monitor and control containers and images on your local machine and a remote NAS, browse Docker Hub repositories and tags.

Specification: widgetcontextprotocol.com⁠ | Part of the Penrith Beacon WCP⁠ widget suite.

WCP 2.1.0 certified. Full theme reception, orchestration-aware state, Publish to Web, WCP export.


⁠Components

ComponentDefault sizeDescription
Local12x6Local Docker host — containers and images
NAS12x6Remote NAS Docker host via wcp-docker-agent
Hub12x6Docker Hub repositories and tags browser
Settings12x6Docker Hub credentials, NAS agent URL and token

⁠Quick Start

docker run -d \
  --name wcp-widget-docker \
  -p 3744:3744 \
  -v /var/run/docker.sock:/var/run/docker.sock \
  -v docker_data:/app/data \
  -v docker_published:/app/published \
  -e CONTAINER_NAME=wcp-widget-docker \
  --restart unless-stopped \
  docker.io/penrithbeacon/wcp-widget-docker:latest

⁠Docker Compose

services:
  docker:
    image: docker.io/penrithbeacon/wcp-widget-docker:latest
    container_name: wcp-widget-docker
    ports:
      - "3744:3744"
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - docker_data:/app/data
      - ./published:/app/published
    environment:
      - CONTAINER_NAME=wcp-widget-docker
    restart: unless-stopped

volumes:
  docker_data:

⁠Setup Guide

Local tab: Works automatically when the Docker socket is mounted.

NAS tab: Requires wcp-docker-agent⁠ running on the remote host. Configure the agent URL and bearer token in Settings.

Hub tab: Requires Docker Hub username and password/PAT in Settings.


⁠WCP Request Headers

HeaderRequiredDescription
Wcp-Instance-IdYesUnique card instance identifier
Wcp-Dashboard-IdYesDashboard installation identifier
Wcp-VersionYesWCP protocol version of the requesting dashboard
Wcp-Widget-IdYesWidget identifier within the dashboard
Wcp-Orchestration-IdNoActive orchestration identifier (for state scoping)
Wcp-Application-IdNoActive application identifier (for state scoping)

⁠Endpoints

EndpointDescription
GET /wcpContainer Directory — WCP two-tier discovery
GET /widget/wcpWidget Manifest with runtime publish status
OPTIONS /wcpCORS preflight (all widget routes)
GET /widget/Compact widget card (iframe)
GET /widget/indexWidget Index — lists all controls
GET /widget/healthHealth check with container name
GET /widget/icon.svgWidget icon (SVG)
GET /widget/api/guidsComponent UUIDs for orchestration binding
GET /widget/localLocal Docker host page
GET /widget/nasNAS Docker host page
GET /widget/hubDocker Hub browser page
GET /widget/settingsSettings page
GET /widget/api/local/containersLocal containers list
GET /widget/api/local/imagesLocal images list
POST /widget/api/local/containers/<cid>/<action>Local container action (start/stop/restart/remove)
GET /widget/api/nas/containersNAS containers list
GET /widget/api/nas/imagesNAS images list
POST /widget/api/nas/testTest NAS agent connection
POST /widget/api/nas/containers/<cid>/<action>NAS container action
GET /widget/api/hub/reposDocker Hub repositories
GET /widget/api/hub/repos/<name>/descriptionRepository description
GET /widget/api/hub/repos/<name>/tagsRepository tags
GET /widget/api/settingsCurrent settings (tokens masked)
POST /widget/api/settingsSave settings
GET /widget/export.wcpSelf-export as .wcp package
POST /widget/publishAccept SPA HTML for Publish to Web
DELETE /widget/publishRemove published SPA
GET /Serve published SPA (if present)

⁠WCP Compatibility

PropertyValue
WCP Version2.1.0
Widget Version1.4.0
Render modeiframe
AuthNone (credentials stored server-side)
Default card size12x6
Multi-instanceYes (per Instance-Id)

⁠Technical Details

PropertyValue
Base imagepython:3.12-slim
Platformslinux/amd64, linux/arm64
Port3744
FrameworkFlask
DependenciesFlask, requests, docker
Persistent storageNamed volume for settings

⁠Tags

TagDescription
latestMost recent stable release
1.4.0-wcp2.1.0/widget/index directory page, audit compliance
1.3.0-wcp2.1.0/widget/health returns container name
1.2.0-wcp2.1.0WCP 2.1.0 upgrade, orchestration ID context
1.1.0-wcp2.0.0Container block, manifest image source
1.0.1-wcp1.4.0Server UUID, Container Directory, Wcp-Widget-Id
1.0.0-wcp1.3.1Initial release

⁠Source

Tag summary

Content type

Image

Digest

sha256:6eff47f89…

Size

47.5 MB

Last updated

4 months ago

docker pull penrithbeacon/wcp-widget-docker