api/server: Server.CreateMux: also register API-version debug endpoints

The debug endpoints are currently only provided non-versioned (e.g. `/debug/vars`).
While this is convenient, we "officially" deprecated non-versioned endpoints
in the API.

This patch also registers the debug-endpoints under the API-versioned paths,
so that they can be used either without version ("latest") and versioned
paths.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2024-12-08 16:11:24 +01:00
parent e2d2834be1
commit 27294df576
2 changed files with 5 additions and 0 deletions

View File

@@ -58,6 +58,10 @@ keywords: "API, Docker, rcli, REST, documentation"
the one that sorts first is picked.
* `GET /containers/json` now returns a `GwPriority` field in `NetworkSettings`
for each network endpoint.
* API debug endpoints (`GET /debug/vars`, `GET /debug/pprof/`, `GET /debug/pprof/cmdline`,
`GET /debug/pprof/profile`, `GET /debug/pprof/symbol`, `GET /debug/pprof/trace`,
`GET /debug/pprof/{name}`) are now also accessible through the versioned-API
paths (`/v<API-version>/<endpoint>`).
## v1.47 API changes