>DevOps Interview KB

What does it actually mean for a container image to be 'OCI-compliant,' and why does that matter beyond just being a compatibility buzzword?

IntermediateConceptualContainers6 min read

Short Answer

The Open Container Initiative (OCI) defines two separate, precise specifications: the Image Specification (exactly how a container image's layers, configuration, and manifest should be structured and serialized) and the Runtime Specification (exactly how a compliant runtime should take a filesystem bundle and actually run it as a container, including namespace/cgroup setup). Compliance with these means an image built by one tool (Docker) can be correctly pulled, inspected, and run by an entirely different tool (containerd, Podman, CRI-O) without either tool needing custom, tool-specific compatibility code — this interoperability is the actual practical value, not just a certification badge.

Detailed Explanation

Before OCI standardization, container image formats and runtime behavior were effectively defined by Docker's own implementation, meaning other tools wanting compatibility had to reverse-engineer or track Docker's specific behavior — OCI formalizing these as independent, documented specifications is what allows a genuinely diverse ecosystem of tools to interoperate reliably.

The Image Specification defines exactly how an image is structured: a manifest describing the image's layers and configuration, a set of content-addressable layer blobs (each layer identified by a cryptographic hash of its content), and a configuration object describing runtime parameters (entrypoint, environment variables, working directory) — because this format is precisely, publicly specified, any tool that produces or consumes OCI-compliant images can do so without needing to understand another specific tool's internal implementation details.

Content-addressable storage (layers identified by hash) enables real deduplication and integrity verification: since each layer is identified by a hash of its own content, identical layers (the same base OS layer used by many different images, for instance) are stored and referenced once regardless of how many images use them, and the hash itself provides a built-in integrity check — a layer that's been tampered with or corrupted won't match its expected hash, which is detectable without needing separate verification tooling.

The Runtime Specification defines exactly how a runtime should execute a container from a filesystem bundle: given an image's extracted filesystem plus a configuration file specifying namespaces, cgroups, mounts, and process parameters, a compliant runtime (like runc, the reference implementation, which containerd uses underneath) must set up the container's isolation and start the specified process in a precisely defined way — this is what lets different higher-level tools (containerd, CRI-O, Podman) all rely on the same underlying runc (or another OCI-compliant low-level runtime) to actually do the namespace/cgroup setup work, rather than each reimplementing it independently.

Practical interoperability is the actual point, not the specification detail itself: because of this standardization, an image built with docker build can be pulled and run by containerd (as covered in the related containerd/Docker/CRI-O comparison), pushed to essentially any OCI-compliant registry, and scanned by any OCI-aware security tool — none of which would work reliably if each tool implemented its own, incompatible image format and runtime behavior, which is genuinely how the ecosystem looked before OCI standardization existed.

This is why "which container tool did you build this with" mostly doesn't matter downstream: as long as the image and runtime are OCI-compliant, the specific tool used to build or run a container is largely an implementation detail from the perspective of anything else in the ecosystem that also speaks OCI — a meaningful practical benefit for an ecosystem with as many different tools (Docker, Podman, Buildah, containerd, CRI-O, and more) as the container space has.

Interview Follow-Up Questions

  • How would you verify that a specific image is genuinely OCI-compliant, rather than using a proprietary or non-standard format?
  • What's the relationship between `runc` and higher-level runtimes like containerd or CRI-O, given `runc` is the reference OCI Runtime Specification implementation?
  • How does OCI compliance relate to (and differ from) Docker's own, historically earlier image format — are they now effectively the same thing?

Key Takeaways

  • OCI defines two separate specifications: the Image Specification (how images are structured and serialized) and the Runtime Specification (how a compliant runtime executes a container from a filesystem bundle).
  • Content-addressable layer storage (hash-identified layers) enables deduplication across images and built-in integrity verification.
  • OCI compliance is what allows genuinely different tools (Docker, containerd, Podman, CRI-O) to interoperate — an image built by one can be reliably run by another, without custom compatibility code.
  • The practical value is ecosystem interoperability, not a certification checkbox — it's why "which tool built this image" is mostly irrelevant to anything downstream that also speaks OCI.

References

Last updated August 22, 2026 · Last reviewed August 22, 2026