Docker Manager
REST API that manages Docker containers through the Docker Engine — list, inspect, and control the lifecycle of running containers.
Overview
Docker Manager is a Spring Boot REST API that acts as a control plane for the Docker Engine. Instead of running docker commands by hand, clients call HTTP endpoints to list, inspect, start, stop, restart, and remove containers — a building block for a self-service container management layer.
GET /containers — JSON listing the running containers (name, image, state, ports). Replace with a browser/curl capture.
Features
GET /containers— list containers with status and ports.GET /containers/{id}— inspect a container’s full config.POST /containers/{id}/start·POST /containers/{id}/stop·POST /containers/{id}/restart— lifecycle control.DELETE /containers/{id}— remove a container.- Result caching to keep repeated list calls cheap.
Tech stack
- Java 17+ / Spring Boot 3 with Gradle and Lombok
- docker-java client for the Docker Engine API
- Spring Cache for read paths
- Runs against
tcp://localhost:2375or the engine’s named pipe
Running locally
# configure the engine endpoint in application.properties (docker.host)
./gradlew bootRun
curl http://localhost:8080/containers
Requires a reachable Docker Engine (on Windows, Docker Desktop’s named pipe works with npipe:////./pipe/docker_engine).
Why this project?
It shows integration with a real infrastructure API (the Docker Engine), endpoint design for system-level resources, and how to write a small but complete backend service that operators would actually script against.