github.com/afxcn/moby@v1.13.1/client/checkpoint_create.go (about)

     1  package client
     2  
     3  import (
     4  	"github.com/docker/docker/api/types"
     5  	"golang.org/x/net/context"
     6  )
     7  
     8  // CheckpointCreate creates a checkpoint from the given container with the given name
     9  func (cli *Client) CheckpointCreate(ctx context.Context, container string, options types.CheckpointCreateOptions) error {
    10  	resp, err := cli.post(ctx, "/containers/"+container+"/checkpoints", nil, options, nil)
    11  	ensureReaderClosed(resp)
    12  	return err
    13  }