feat: add Docker container management functionality

- Implement DockerHandler to handle API requests for listing Docker containers.
- Create DockerService to interact with Docker API and retrieve container information.
- Add routes for Docker container management in the API.
- Introduce frontend API integration for Docker container listing.
- Enhance ProxyHostForm to allow quick selection of Docker containers.
- Update Docker-related tests to ensure functionality and error handling.
- Modify Docker Compose files to enable Docker socket access for local and remote environments.
- Add TypeScript configurations for improved build processes.
This commit is contained in:
Wikid82
2025-11-20 21:27:02 -05:00
parent 8c67e656b9
commit 9f62a4a2df
27 changed files with 691 additions and 71 deletions

19
docker-compose.remote.yml Normal file
View File

@@ -0,0 +1,19 @@
version: '3.9'
services:
# Run this service on your REMOTE servers (not the one running CPMP)
# to allow CPMP to discover containers running there.
docker-socket-proxy:
image: alpine/socat
container_name: docker-socket-proxy
restart: unless-stopped
ports:
# Expose port 2375.
# ⚠️ SECURITY WARNING: Ensure this port is NOT accessible from the public internet!
# Use a VPN (Tailscale, WireGuard) or a private local network (LAN).
- "2375:2375"
volumes:
# Give the proxy access to the host's Docker socket
- /var/run/docker.sock:/var/run/docker.sock
# Forward TCP traffic from port 2375 to the internal Docker socket
command: tcp-listen:2375,fork,reuseaddr unix-connect:/var/run/docker.sock