aboutsummaryrefslogtreecommitdiff
path: root/pkg/api/server
diff options
context:
space:
mode:
authorJhon Honce <jhonce@redhat.com>2021-01-07 15:25:44 -0700
committerJhon Honce <jhonce@redhat.com>2021-01-07 15:32:32 -0700
commitb059e1044f5a1bac6a531e6241e24f82c8c6a9c0 (patch)
tree9e40297a48967cb64d2f3325f9ee15b3ea31aa7f /pkg/api/server
parent78cda71372485f163909525f8d07194920968486 (diff)
downloadpodman-b059e1044f5a1bac6a531e6241e24f82c8c6a9c0.tar.gz
podman-b059e1044f5a1bac6a531e6241e24f82c8c6a9c0.tar.bz2
podman-b059e1044f5a1bac6a531e6241e24f82c8c6a9c0.zip
Restore compatible API for prune endpoints
* Restore correct API endpoint payloads including reclaimed space numbers * Include tests for API prune endpoints * Clean up function signatures with unused parameters * Update swagger for /networks/prune Fixes #8891 Signed-off-by: Jhon Honce <jhonce@redhat.com>
Diffstat (limited to 'pkg/api/server')
-rw-r--r--pkg/api/server/register_networks.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/pkg/api/server/register_networks.go b/pkg/api/server/register_networks.go
index e6c85d244..967d7da76 100644
--- a/pkg/api/server/register_networks.go
+++ b/pkg/api/server/register_networks.go
@@ -9,6 +9,19 @@ import (
)
func (s *APIServer) registerNetworkHandlers(r *mux.Router) error {
+ // swagger:operation POST /networks/prune compat compatPruneNetwork
+ // ---
+ // tags:
+ // - networks (compat)
+ // Summary: Delete unused networks
+ // description: Not supported
+ // produces:
+ // - application/json
+ // responses:
+ // 404:
+ // $ref: "#/responses/NoSuchNetwork"
+ r.HandleFunc(VersionedPath("/networks/prune"), compat.UnsupportedHandler).Methods(http.MethodPost)
+ r.HandleFunc("/networks/prune", compat.UnsupportedHandler).Methods(http.MethodPost)
// swagger:operation DELETE /networks/{name} compat compatRemoveNetwork
// ---
// tags: