diff --git a/Sources/Containerization/Image/ImageStore/ImageStore+Import.swift b/Sources/Containerization/Image/ImageStore/ImageStore+Import.swift index 730e5779..7dc4eb4a 100644 --- a/Sources/Containerization/Image/ImageStore/ImageStore+Import.swift +++ b/Sources/Containerization/Image/ImageStore/ImageStore+Import.swift @@ -211,7 +211,12 @@ extension ImageStore { let platform = supportedPlatforms.first! var root = root root.platform = platform - let index = ContainerizationOCI.Index(schemaVersion: 2, manifests: [root]) + let index = ContainerizationOCI.Index( + schemaVersion: 2, manifests: [root], + annotations: [ + // indicate that this is a synthesized index which is not directly user facing + AnnotationKeys.containerizationIndexIndirect: "true" + ]) return index default: throw ContainerizationError(.internalError, message: "Failed to create index for descriptor \(root.digest), media type \(root.mediaType)") diff --git a/Sources/ContainerizationOCI/AnnotationKeys.swift b/Sources/ContainerizationOCI/AnnotationKeys.swift index d20b6fc7..de8d9df2 100644 --- a/Sources/ContainerizationOCI/AnnotationKeys.swift +++ b/Sources/ContainerizationOCI/AnnotationKeys.swift @@ -17,6 +17,7 @@ /// AnnotationKeys contains a subset of "dictionary keys" for commonly used annotations in an OCI Image Descriptor /// https://github.com/opencontainers/image-spec/blob/main/annotations.md public struct AnnotationKeys: Codable, Sendable { + public static let containerizationIndexIndirect = "com.apple.containerization.index.indirect" public static let containerizationImageName = "com.apple.containerization.image.name" public static let containerdImageName = "io.containerd.image.name" public static let openContainersImageName = "org.opencontainers.image.ref.name"