From 12e78155e1c119f0073a4c3e13486600897cadca Mon Sep 17 00:00:00 2001 From: Brent Baude Date: Mon, 23 Mar 2020 09:12:04 -0500 Subject: apiv2 container commit for libpod add an endpoint for a libpod specific commit. add the abilility to define the format. also update documentation accordingly. Fixes: #5586 Signed-off-by: Brent Baude --- pkg/api/server/register_images.go | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'pkg/api/server') diff --git a/pkg/api/server/register_images.go b/pkg/api/server/register_images.go index e6ad045a2..87ddf5add 100644 --- a/pkg/api/server/register_images.go +++ b/pkg/api/server/register_images.go @@ -978,6 +978,7 @@ func (s *APIServer) registerImagesHandlers(r *mux.Router) error { // name: container // type: string // description: the name or ID of a container + // required: true // - in: query // name: repo // type: string @@ -1000,8 +1001,14 @@ func (s *APIServer) registerImagesHandlers(r *mux.Router) error { // description: pause the container before committing it // - in: query // name: changes + // description: instructions to apply while committing in Dockerfile format (i.e. "CMD=/bin/foo") + // type: array + // items: + // type: string + // - in: query + // name: format // type: string - // description: instructions to apply while committing in Dockerfile format + // description: format of the image manifest and metadata (default "oci") // produces: // - application/json // responses: @@ -1011,6 +1018,6 @@ func (s *APIServer) registerImagesHandlers(r *mux.Router) error { // $ref: '#/responses/NoSuchImage' // 500: // $ref: '#/responses/InternalError' - r.Handle(VersionedPath("/commit"), s.APIHandler(compat.CommitContainer)).Methods(http.MethodPost) + r.Handle(VersionedPath("/libpod/commit"), s.APIHandler(libpod.CommitContainer)).Methods(http.MethodPost) return nil } -- cgit v1.2.3-54-g00ecf