mirror of https://github.com/containers/podman.git
				
				
				
			Merge pull request #6227 from adrianreber/typo
Fix checkpoint --leave-running
This commit is contained in:
		
						commit
						a88cd9a22e
					
				|  | @ -45,7 +45,7 @@ func init() { | ||||||
| 	}) | 	}) | ||||||
| 	flags := checkpointCommand.Flags() | 	flags := checkpointCommand.Flags() | ||||||
| 	flags.BoolVarP(&checkpointOptions.Keep, "keep", "k", false, "Keep all temporary checkpoint files") | 	flags.BoolVarP(&checkpointOptions.Keep, "keep", "k", false, "Keep all temporary checkpoint files") | ||||||
| 	flags.BoolVarP(&checkpointOptions.LeaveRuninng, "leave-running", "R", false, "Leave the container running after writing checkpoint to disk") | 	flags.BoolVarP(&checkpointOptions.LeaveRunning, "leave-running", "R", false, "Leave the container running after writing checkpoint to disk") | ||||||
| 	flags.BoolVar(&checkpointOptions.TCPEstablished, "tcp-established", false, "Checkpoint a container with established TCP connections") | 	flags.BoolVar(&checkpointOptions.TCPEstablished, "tcp-established", false, "Checkpoint a container with established TCP connections") | ||||||
| 	flags.BoolVarP(&checkpointOptions.All, "all", "a", false, "Checkpoint all running containers") | 	flags.BoolVarP(&checkpointOptions.All, "all", "a", false, "Checkpoint all running containers") | ||||||
| 	flags.BoolVarP(&checkpointOptions.Latest, "latest", "l", false, "Act on the latest container podman is aware of") | 	flags.BoolVarP(&checkpointOptions.Latest, "latest", "l", false, "Act on the latest container podman is aware of") | ||||||
|  |  | ||||||
|  | @ -170,7 +170,7 @@ type CheckpointOptions struct { | ||||||
| 	IgnoreRootFS   bool | 	IgnoreRootFS   bool | ||||||
| 	Keep           bool | 	Keep           bool | ||||||
| 	Latest         bool | 	Latest         bool | ||||||
| 	LeaveRuninng   bool | 	LeaveRunning   bool | ||||||
| 	TCPEstablished bool | 	TCPEstablished bool | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -434,6 +434,7 @@ func (ic *ContainerEngine) ContainerCheckpoint(ctx context.Context, namesOrIds [ | ||||||
| 		TCPEstablished: options.TCPEstablished, | 		TCPEstablished: options.TCPEstablished, | ||||||
| 		TargetFile:     options.Export, | 		TargetFile:     options.Export, | ||||||
| 		IgnoreRootfs:   options.IgnoreRootFS, | 		IgnoreRootfs:   options.IgnoreRootFS, | ||||||
|  | 		KeepRunning:    options.LeaveRunning, | ||||||
| 	} | 	} | ||||||
| 
 | 
 | ||||||
| 	if options.All { | 	if options.All { | ||||||
|  |  | ||||||
|  | @ -267,7 +267,7 @@ func (ic *ContainerEngine) ContainerCheckpoint(ctx context.Context, namesOrIds [ | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| 	for _, c := range ctrs { | 	for _, c := range ctrs { | ||||||
| 		report, err := containers.Checkpoint(ic.ClientCxt, c.ID, &options.Keep, &options.LeaveRuninng, &options.TCPEstablished, &options.IgnoreRootFS, &options.Export) | 		report, err := containers.Checkpoint(ic.ClientCxt, c.ID, &options.Keep, &options.LeaveRunning, &options.TCPEstablished, &options.IgnoreRootFS, &options.Export) | ||||||
| 		if err != nil { | 		if err != nil { | ||||||
| 			reports = append(reports, &entities.CheckpointReport{Id: c.ID, Err: err}) | 			reports = append(reports, &entities.CheckpointReport{Id: c.ID, Err: err}) | ||||||
| 		} | 		} | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue