export declare const MEDIA_TYPE: {
  manifest: 'application/vnd.oci.image.manifest.v1+json';
  manifestList: 'application/vnd.oci.image.index.v1+json';
  config: 'application/vnd.oci.image.config.v1+json';
  layerGzip: 'application/vnd.oci.image.layer.v1.tar+gzip';
  dockerManifest: 'application/vnd.docker.distribution.manifest.v2+json';
  dockerManifestList: 'application/vnd.docker.distribution.manifest.list.v2+json';
  dockerConfig: 'application/vnd.docker.container.image.v1+json';
  dockerLayerGzip: 'application/vnd.docker.image.rootfs.diff.tar.gzip'
};
/**
 * Native container ("Docker") support for pantry.
 *
 * pantry can parse + build a `Dockerfile` into an OCI image without shelling
 * out to the `docker` daemon. The build context is filtered by a `.freezer`
 * file — pantry's home-themed equivalent of `.dockerignore` (a `.dockerignore`
 * is honored as a fallback for compatibility).
 */
/** A single parsed Dockerfile instruction. */
export declare interface DockerInstruction {
  instruction: string
  args: string
  flags: Record<string, string>
  line: number
}
/** One build stage (everything from a `FROM` up to the next `FROM`). */
export declare interface DockerStage {
  name?: string
  baseImage: string
  platform?: string
  index: number
  instructions: DockerInstruction[]
}
/** A fully parsed Dockerfile. */
export declare interface ParsedDockerfile {
  directives: Record<string, string>
  globalArgs: DockerInstruction[]
  stages: DockerStage[]
  instructions: DockerInstruction[]
}
/**
 * OCI image config (the `config` blob). Mirrors the subset of the OCI image
 * spec that the builder populates.
 */
export declare interface OciImageConfig {
  architecture: string
  os: string
  config: {
    User?: string
    ExposedPorts?: Record<string, Record<string, never>>
    Env?: string[]
    Entrypoint?: string[]
    Cmd?: string[]
    Volumes?: Record<string, Record<string, never>>
    WorkingDir?: string
    Labels?: Record<string, string>
    StopSignal?: string
  }
  rootfs: {
    type: 'layers'
    diff_ids: string[]
  }
  history: Array<{
    created?: string
    created_by?: string
    comment?: string
    empty_layer?: boolean
  }>
  created?: string
}
/** A built layer: its uncompressed (diffID) and compressed (digest) identities. */
export declare interface BuiltLayer {
  digest: string
  diffId: string
  size: number
  path: string
}
/** An OCI descriptor (used in manifests/indexes). */
export declare interface OciDescriptor {
  mediaType: string
  digest: string
  size: number
  platform?: { architecture: string, os: string }
  annotations?: Record<string, string>
}
/** OCI image manifest. */
export declare interface OciManifest {
  schemaVersion: 2
  mediaType: string
  config: OciDescriptor
  layers: OciDescriptor[]
  annotations?: Record<string, string>
}
/** Options for building an image from a Dockerfile. */
export declare interface BuildOptions {
  context: string
  dockerfile?: string
  tags?: string[]
  buildArgs?: Record<string, string>
  target?: string
  outputDir?: string
  platform?: string
  quiet?: boolean
  runMode?: 'auto' | 'chroot' | 'host' | 'skip'
}
/** Result of a build. */
export declare interface BuildResult {
  imageId: string
  tags: string[]
  archivePath?: string
  ociLayoutPath?: string
  config: OciImageConfig
  layers: BuiltLayer[]
  configBytes: Uint8Array
  configDigest: string
  manifestBytes: Uint8Array
  manifestMediaType: string
}
/** A parsed image reference (registry/repository:tag@digest). */
export declare interface ImageReference {
  registry: string
  repository: string
  tag: string
  digest?: string
  implicitRegistry: boolean
}
