# Build Artifacts & Registries — CI/CD Fundamentals: Pipelines, Testing and Deployment

Source: https://www.skillbyai.com/en/cicd/cicd-artifacts

> Store versioned, immutable build artifacts in a registry so the same tested output is deployed everywhere.

## What an artifact is

An **artifact** is the concrete output of the build stage — a Docker image, a JAR, a compiled binary, a static JS bundle. It's what actually gets tested and deployed, not the source code itself.

## Versioning

Every artifact gets an immutable identifier — a semantic version, a git commit SHA, or a build number. This lets you say precisely what's running in production, and redeploy that exact same build if needed.

## A labelled warehouse

An **artifact registry** (Docker Hub, npm registry, a private registry) is a warehouse where every box (artifact) has a clear label (version). Anywhere that needs to deploy just orders the exact labelled box — no guessing which one is which.

**Quiz:** Why should each build artifact get an immutable version identifier?

- [ ] It makes the build run faster
- [ ] It removes the need for a registry
- [ ] It makes images smaller
- [x] It lets you know exactly what's running and redeploy that exact build later

*Answer:* It lets you know exactly what's running and redeploy that exact build later. A stable, unique identifier turns 'some build' into a traceable, reproducible artifact you can point at and redeploy.
