mirror of
https://github.com/containers/podman.git
synced 2025-12-16 03:57:36 +08:00
Add GET /quadlets/{name}/file
Fixes: https://issues.redhat.com/browse/RUN-3716 Signed-off-by: Nicola Sella <nsella@redhat.com>
This commit is contained in:
@@ -32,5 +32,27 @@ func (s *APIServer) registerQuadletHandlers(r *mux.Router) error {
|
||||
// 500:
|
||||
// $ref: "#/responses/internalError"
|
||||
r.HandleFunc(VersionedPath("/libpod/quadlets/json"), s.APIHandler(libpod.ListQuadlets)).Methods(http.MethodGet)
|
||||
// swagger:operation GET /libpod/quadlets/{name}/file libpod QuadletFileLibpod
|
||||
// ---
|
||||
// tags:
|
||||
// - quadlets
|
||||
// summary: Get quadlet file
|
||||
// description: Get the contents of a Quadlet, displaying the file including all comments
|
||||
// produces:
|
||||
// - text/plain
|
||||
// parameters:
|
||||
// - in: path
|
||||
// name: name
|
||||
// type: string
|
||||
// required: true
|
||||
// description: the name of the quadlet with extension (e.g., "myapp.container")
|
||||
// responses:
|
||||
// 200:
|
||||
// $ref: "#/responses/quadletFileResponse"
|
||||
// 404:
|
||||
// $ref: "#/responses/quadletNotFound"
|
||||
// 500:
|
||||
// $ref: "#/responses/internalError"
|
||||
r.HandleFunc(VersionedPath("/libpod/quadlets/{name}/file"), s.APIHandler(libpod.GetQuadletPrint)).Methods(http.MethodGet)
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user