Azure Container Registry (ACR) is a key component for managing container images in the cloud. This article breaks down the underlying storage architecture, from registries and repositories down to artifacts, tags, layers, and manifests.
Registries
A registry is a top-level logical container that holds all your container images and related artifacts. Each Azure subscription can have multiple registries, and they can be geo-replicated for performance and compliance.
Repositories
Within a registry, repositories organize related images or artifacts. For example, you might have a repository for your web app, another for an AI model, and a third for a database. Repositories help segregate images by project or purpose.
Artifacts
An artifact is a single item stored in a repository, such as a container image, Helm chart, or OCI artifact. Each artifact is identified by a unique combination of repository name and tag or digest.
Tags and Layers
Tags are human-readable labels (e.g., v1, latest) that point to a specific image version. Behind the scenes, an image is composed of layers stacked on top of each other, and a manifest describes these layers. This layered approach enables efficient storage and fast pull operations because only new layers are transferred.
Manifests
A manifest contains metadata about an image: layers, architecture, OS, and configuration. When you push an image, Azure Container Registry stores both the manifest and the layers. When you pull an image, the manifest is fetched first, then the required layers.
Practical Tips
- Use tags to version your images (e.g.,
myapp:1.0.0). Avoid usinglatestfor production. - Enable geo-replication if your users are globally distributed.
- Use lifecycle policies to automatically delete old, unused images.
- For AI workloads, consider storing model files as OCI artifacts in separate repositories.
Conclusion
Understanding the storage hierarchy of Azure Container Registry helps you optimize container workflows and manage artifacts efficiently. Whether you're preparing for certification or building production AI applications, this foundation is essential.
This article is part of the Azure AI Cloud Developer Ultimate Course series (AI-200).