Skip to content

Commit edc826a

Browse files
authored
Merge pull request #706 from q384566678/add-platcheck
schema: add check platform to manifests
2 parents 634a86b + 4fddb94 commit edc826a

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

schema/validator.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,9 @@ func validateIndex(r io.Reader) error {
164164
if manifest.MediaType != string(v1.MediaTypeImageManifest) {
165165
fmt.Printf("warning: manifest %s has an unknown media type: %s\n", manifest.Digest, manifest.MediaType)
166166
}
167+
if manifest.Platform != nil {
168+
checkPlatform(manifest.Platform.OS, manifest.Platform.Architecture)
169+
}
167170

168171
}
169172

0 commit comments

Comments
 (0)