Skip to content

Commit

Permalink
Fix snapshot key error
Browse files Browse the repository at this point in the history
When obtaining the container information fails, the key for deleting the snapshot is incorrect.

Signed-off-by: wangqiang <[email protected]>
  • Loading branch information
wangqiang authored and alexellis committed Mar 20, 2024
1 parent 70b0929 commit dd31784
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/service/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ func Remove(ctx context.Context, client *containerd.Client, name string) error {

} else {
service := client.SnapshotService("")
key := name + "snapshot"
key := name + "-snapshot"
if _, err := client.SnapshotService("").Stat(ctx, key); err == nil {
service.Remove(ctx, key)
}
Expand Down

0 comments on commit dd31784

Please sign in to comment.