diff --git a/cmd/ctr/commands/content/content.go b/cmd/ctr/commands/content/content.go index 02f7285bb..ed78e3d12 100644 --- a/cmd/ctr/commands/content/content.go +++ b/cmd/ctr/commands/content/content.go @@ -21,6 +21,7 @@ import ( "fmt" "io" "os" + "sort" "strings" "text/tabwriter" "time" @@ -211,6 +212,7 @@ var ( for k, v := range info.Labels { labelStrings = append(labelStrings, strings.Join([]string{k, v}, "=")) } + sort.Strings(labelStrings) labels := strings.Join(labelStrings, ",") if labels == "" { labels = "-"