Skip to content

Image Deploy

This diagram provides a high-level description of Image Deploy.

image-deploy image

What Is Image Deployment?

Image deployment is an alternative OS provisioning method where DRP streams a pre-built disk image directly to a target machine rather than running an OS installer. Instead of executing a kickstart or preseed-driven installation (which installs packages from repositories and generates configuration at install time), image deployment writes a known-good snapshot of an entire OS — filesystem, packages, configuration, and all — to the target disk. The result is a machine that boots into an already-installed OS in a fraction of the time a traditional installer would take.

Image deployment is particularly useful when:

  • Provisioning speed is critical and installer-based methods are too slow.
  • The target OS requires a specific, validated state that is difficult to reproduce reliably via an installer (for example, a GPU driver stack, a validated compliance baseline, or a complex application framework).
  • Immutable infrastructure patterns are in use, where a single golden image is applied uniformly across a machine class rather than configured per-machine.

How DRP Streams Images to Targets

Image deployment in DRP runs inside Sledgehammer, the in-memory discovery OS. From Sledgehammer, the DRP machine agent executes image-deploy tasks that:

  1. Download the image. The image is fetched from DRP's built-in file server (or from an object storage URL referenced by DRP parameters). DRP's file server supports partial-read (HTTP range) transfers, allowing the streaming decompression pipeline to begin before the full image is downloaded.

  2. Write the image to disk. The image is decompressed on the fly and written to the target block device using standard Linux utilities (dd, xzcat, zstd, etc.). The image-deploy content pack provides tasks that handle common image formats and decompression algorithms, selecting the appropriate pipeline based on the image format parameter.

  3. Inject machine-specific configuration. After writing the image, tasks mount the freshly written filesystem and inject per-machine configuration: hostname, network interface settings, DRP agent bootstrap configuration, and SSH keys. This customization step is what allows a single golden image to be deployed to many machines with different identities.

  4. Install the DRP agent. The agent (dr-provision-agent) is installed into the imaged OS so that it starts on first boot and connects back to DRP to continue the workflow (post-install configuration, validation, and application deployment).

Image Format Requirements

DRP image deployment supports raw disk images (optionally compressed with gzip, xz, or zstd) and filesystem-level images. Raw disk images include partition table and all partitions, allowing DRP to deploy a complete disk layout in a single operation. The image must be built to match the target hardware's disk geometry (sector size, partition alignment) and boot method (BIOS MBR or UEFI GPT).

Images are typically built using tools like dd, Packer, or custom build pipelines and stored in object storage. DRP parameters on the machine or profile record the image URL, format, and checksum. The checksum is verified before writing begins to ensure image integrity.

Image Deploy vs. Traditional Install

Aspect Traditional PXE Install Image Deploy
Speed Minutes to tens of minutes Seconds to a few minutes
Reproducibility Varies with package versions and installer behavior Deterministic — same image every time
Customization Per-machine via kickstart parameters Post-image injection of minimal per-machine config
Image size Not applicable (packages pulled from repo) Full disk image (typically 2–20 GB compressed)
OS variety Any OS with a network installer Any OS that can be imaged; requires image build pipeline
Best for Environments needing flexible OS configuration Large-scale, speed-critical, or immutable infrastructure

Traditional installer-based provisioning remains the right choice when per-machine OS configuration variation is high, when the target OS does not support raw disk imaging, or when storage bandwidth is a constraint. Image deployment is preferred when uniformity, speed, and reproducibility are the primary requirements.

Read More