mirror of
https://github.com/goharbor/harbor.git
synced 2025-02-06 23:11:31 +01:00
fix gc remove manifest issue (#12748)
fixes #12720 The GC job doesn't remove the manifest of scheme1.MediaTypeSignedManifest as it's recognized by GC job. Signed-off-by: wang yan <wangyan@vmware.com>
This commit is contained in:
parent
e476286fdc
commit
01e4aa61f7
@ -88,8 +88,10 @@ func (b *Blob) IsForeignLayer() bool {
|
||||
|
||||
// IsManifest returns true if the blob is manifest layer
|
||||
func (b *Blob) IsManifest() bool {
|
||||
return b.ContentType == schema2.MediaTypeManifest || b.ContentType == schema1.MediaTypeManifest ||
|
||||
b.ContentType == v1.MediaTypeImageManifest || b.ContentType == v1.MediaTypeImageIndex || b.ContentType == manifestlist.MediaTypeManifestList
|
||||
return b.ContentType == schema2.MediaTypeManifest ||
|
||||
b.ContentType == schema1.MediaTypeManifest || b.ContentType == schema1.MediaTypeSignedManifest ||
|
||||
b.ContentType == v1.MediaTypeImageManifest || b.ContentType == v1.MediaTypeImageIndex ||
|
||||
b.ContentType == manifestlist.MediaTypeManifestList
|
||||
}
|
||||
|
||||
// ProjectBlob alias ProjectBlob model
|
||||
|
Loading…
Reference in New Issue
Block a user