We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 3289dc6 + fc2fcf6 commit 26e2dd6Copy full SHA for 26e2dd6
1 file changed
cmd/ctr/commands/tasks/checkpoint.go
@@ -78,12 +78,22 @@ func withExit(rt string) containerd.CheckpointTaskOpts {
78
return func(r *containerd.CheckpointTaskInfo) error {
79
switch rt {
80
case "io.containerd.runc.v1":
81
- r.Options = &options.CheckpointOptions{
82
- Exit: true,
+ if r.Options == nil {
+ r.Options = &options.CheckpointOptions{
83
+ Exit: true,
84
+ }
85
+ } else {
86
+ opts, _ := r.Options.(*options.CheckpointOptions)
87
+ opts.Exit = true
88
}
89
default:
- r.Options = &runctypes.CheckpointOptions{
90
91
+ r.Options = &runctypes.CheckpointOptions{
92
93
94
95
+ opts, _ := r.Options.(*runctypes.CheckpointOptions)
96
97
98
99
return nil
0 commit comments