Immutable Linux Appliance: Measured Boot, Verified A/B Updates and a Device-Bound Disk

Rebuild a laboratory-results relay as an image-based appliance: a signed Debian 13 image built with mkosi, your own Secure Boot keys and unified kernel images, a dm-verity /usr in A/B slots, updates with systemd-sysupdate that roll themselves back, a state partition bound to the TPM with a signed PCR policy, remote attestation from TPM quotes, and releases in rings.

Linux / Systems Engineer. Advanced.

What you will build and explain

  • Explain why an appliance should run a signed, read-only image with A/B slots, and build one from pinned Debian packages with mkosi.
  • Own a device's UEFI Secure Boot keys, sign its boot loader and unified kernel images, and explain what PCR 7 records.
  • Protect /usr with dm-verity and bind its root hash to a signed kernel command line, so only the release's own /usr can be mounted.
  • Create an encrypted state partition on first boot, bound with LUKS2 to the TPM through PCR 7 and a signed PCR 11 policy that survives updates, escrow a recovery secret, and verify the enrolled policy on each device.
  • Update with systemd-sysupdate from a signed release, survive power cuts mid-update, and let boot counting and a health check roll a bad release back with nobody on site.
  • Prove what a device booted with TPM keys, credential activation, quotes and event logs, and catch a withdrawn release.
  • Release to a fleet in rings gated on fresh, attested evidence, and halt a bad release at the canary.
  • Monitor the fleet with tested alerting rules and runbooks, run eight failure drills, and explain the design's limits and production changes.

Before you begin

  • Linux terminal use and editing files; reading short Bash and Python programs; Docker basics; what a disk partition, a filesystem and DHCP are.
  • An x86-64 Linux host with hardware virtualization (/dev/kvm; nested virtualization on a cloud VM), 8 CPUs, 16 GB of memory, 60 GB of free disk, Docker 27 or later with the Compose plugin, and your user in the docker and kvm groups. UEFI and Secure Boot, systemd-boot and unified kernel images, mkosi, dm-verity, TPM 2.0, LUKS2, systemd-sysupdate, boot assessment, attestation, Prometheus and Alertmanager are taught.

Who this is for

For Linux and systems engineers who run servers or field devices and can read Bash and Python but have not built an image-based operating system: rebuild a hospital laboratory relay as a signed, read-only image with mkosi, own its Secure Boot keys, verify /usr with dm-verity, bind its encrypted data to the TPM, update it in A/B slots that roll back by themselves, prove each boot to a fleet controller and release in gated rings, with every failure reproduced on purpose.

Curriculum

Learning topics (15)
  1. Tarrant's relays, the release pipeline and the fleet

    Tarrant Diagnostics' relay sits in a hospital laboratory, receives results from analysers, keeps them in a queue and forwards them to the hospital's laboratory information system. This project rebuilds it as an image-based appliance: one signed image, a boot chain that refuses anything Tarrant did not sign, an operating system that cannot be changed, updates that can always go back, data that only its own relay can read, and a fleet controller that can tell which relays boote

  2. Prepare the lab host, and the ideas the lessons build on

    This project builds an appliance from the firmware up, so it touches many layers of a computer. This lesson says what you need to know already, what the project teaches you, and the handful of ideas every later lesson relies on: hashes and signatures, certificates, and the difference between a container and a virtual machine. It ends with the checks that tell you whether your host can run the lab.

  3. Why an appliance runs an image, not a package set

    Tarrant's old relays were Debian installations patched by hand. No two were alike, an interrupted upgrade could leave one unbootable, and nobody could say what a given relay was running. This lesson explains the alternative the project builds: an operating system delivered as one signed image, which a relay cannot change and can always replace with the previous one.

  4. UEFI, firmware variables and owning the Secure Boot keys

    The first program a relay runs is its firmware, and the firmware decides what runs next. If anything at that first step can be replaced, nothing later can be trusted. This lesson explains UEFI firmware, how Secure Boot decides which programs may start, and why Tarrant enrols its own keys instead of the keys general-purpose computers ship with.

  5. systemd-boot, unified kernel images and a sealed command line

    Secure Boot checks a program's signature before starting it. On a typical Linux system that protects the boot loader and the kernel, but not the initrd or the kernel's command line, which sit beside them as separate files anyone with the disk can edit. This lesson explains the unified kernel image (UKI), which puts all of them into one signed file, and systemd-boot, the boot loader that chooses which UKI to start.

  6. mkosi, pinned packages and reproducible builds

    An image-based system is only as trustworthy as the way its images are made. This lesson follows one release through Tarrant's pipeline: what mkosi builds from which inputs, which key signs which part, what is published, and what "reproducible" can honestly mean for a Debian-based image.

  7. Partitions, dm-verity and a hermetic /usr

    A read-only mount stops software on a relay from changing /usr. It does not stop someone with the disk from changing it, or a failing disk from corrupting it. This lesson explains dm-verity, which checks every block of /usr against one hash every time it is read, and how the relay's partitions and command line fit together so that only the right /usr is ever mounted.

  8. TPM 2.0, PCRs and the event log

    Secure Boot answers "may this program run?". It does not leave a record of what did run, and it cannot tell anyone else. This lesson explains the TPM, the chip that keeps such a record in a form that cannot be rewritten, and the event logs that explain the record. The next lessons use it twice: to release a disk key only to the right boot (the Device-bound state lesson), and to prove a boot to the fleet controller (the Attestation lesson).

  9. First boot, LUKS2 and signed PCR policies

    A relay holds patient results until the laboratory system has them. One of Tarrant's old relays was stolen from a hospital, and its disk was readable on any computer. The new relay must keep that data unreadable anywhere except on the relay it was written on, running software Tarrant released, and it must still start by itself after a power cut with no one to type a password. This lesson shows how a TPM makes that possible, and how a relay's disk can look encrypted while prot

  10. systemd-sysupdate, slots and signed releases

    An update is the riskiest thing an appliance does: it changes the software that has to boot next time, often with nobody on site. This lesson follows one update on a relay, from the controller's target to a new release written and ready to boot, and shows why a relay that loses power at any moment still boots.

  11. Boot counting, health and automatic rollback

    An update has written release 3 next to release 2. Whether release 3 stays must be decided by the relay itself, on its first boot, with nobody watching and possibly no network. This lesson explains systemd's automatic boot assessment: tries counted in the boot entry's file name, a health check that decides, and a boot loader that falls back by itself.

  12. Proving what booted, from the factory to a verdict

    Secure Boot and the TPM protect a relay locally. Tarrant still cannot see 300 relays in 300 hospitals. A relay could be running an old release, someone could have changed its firmware settings, or the "relay" answering could be a program pretending to be one. This lesson builds remote attestation: a relay proves to the fleet controller, with a signature only its TPM can make, exactly what it booted.

  13. The fleet controller and releases in rings

    A relay can protect itself from a bad release by rolling back. The fleet still needs protecting from a bad release reaching 300 relays at once, and someone must decide which relay runs what. This lesson explains Tarrant's fleet controller: how relays talk to it, how a release moves through rings, and what evidence opens each ring or stops the rollout.

  14. Fleet metrics, alerts and runbooks

    Everything in the earlier lessons produces evidence: a rollback, a verity error, an untrusted verdict, a silent relay. None of it helps if nobody hears about it. This lesson explains how the lab turns that evidence into metrics, the metrics into nine alerts, and each alert into a page with a runbook section saying what to do.

  15. Keys in hardware, revocation, real firmware and the cloud

    The lab runs the whole design on one host: four virtual relays, software TPMs, keys in files, one controller. Every mechanism is real, but some choices only make sense for a lab. This lesson lists what Tarrant would change before shipping relays to hospitals, and why, so you can tell a design decision from a lab shortcut.

Practical build steps (7)
  1. Prepare the lab host

    Starting point: a copy of the project source and a Linux host. Finishing point: a host that can run four virtual relays, and the static checks passing.

  2. Bring the lab up and look inside a relay

    Starting point: a prepared host with the static checks passing. Finishing point: the release pipeline's keys, the services, release 1 and four relays that booted, encrypted their own state partitions, proved their TPM keys to the controller and were attested as trusted; and you have read one relay's firmware, certificates and disk from the host.

  3. Release 2 through the rings

    Starting point: four relays trusted on release 1. Finishing point: release 2 built, signed, published and registered, and rolled out ring by ring until every relay runs it from its other slot, blessed and trusted; and you have watched the relays hold results through a laboratory-system outage.

  4. Make a change, release it, and roll it back

    Starting point: every relay on release 2. Finishing point: a change of your own in a new release on every relay, and every relay back on release 2 through an approved rollback.

  5. Drills: failed updates and power cuts

    Starting point: every relay healthy and trusted. Finishing point: you have seen the update design recover by itself from a release that fails its health check, a release whose kernel cannot start, and two power cuts in the middle of an update.

  6. Drills: the boot chain, the TPM and corruption

    Starting point: every relay healthy and trusted, after the update drills. Finishing point: you have seen the firmware refuse an unsigned boot loader, the TPM refuse to release a state key three ways, a recovery secret open a disk in the workshop, attestation catch a withdrawn release, and dm-verity catch corrupted blocks.

  7. Remove the lab

    Starting point: the lab in any state, including a failed step. Finishing point: nothing of the lab left on the host: no container, network, volume, tap device, image or generated folder, and no private key.

Access

Learning Access: INR 199 plus 18% GST. Source Pack: INR 399 plus 18% GST. 90 days of online access. No auto-renewal.

Cloud costs and boundaries

Runs entirely on a Linux host you provide; the project itself has no cloud resources. A cloud virtual machine works only if its provider offers nested virtualization, and it is billed by the hour from creation until you delete it. Cleanup removes everything the lab created on the host, including its keys; deleting a cloud instance is your last step.

Licence and completion

Vectametric Project Source Licence (2026-09-27): personal learning, modification/deployment and attributed portfolio/interview demonstrations are permitted. Lawfully obtained copies remain usable after online access expires. Do not redistribute original source or the Source Pack; commercial/client production use requires separate written permission. Third-party terms remain separate. See included LICENSE.txt and the Project Source Licence section of the site Terms.

Questions about projects

Do I need a cloud account?

You can read the project material without deploying it. Running a cloud build requires the accounts, permissions and tools listed in that project's prerequisites. Deployment runs in your environment, not in a hosted Vectametric lab.

Can I read the code with Learning Access?

Yes. Learning Access includes the online source-file browser and explanations. The Source Pack adds the downloadable reference repository where available. The project's licence governs use of the source.

Are cloud charges included?

No. Cloud and CI usage are separate. Read the project's cost notice, set a budget and stop deadline, and follow its destruction and leftover-resource checks.

Does the project include troubleshooting and interview preparation?

The project curriculum lists the available scenarios and interview topics. These focus on understanding the architecture and explaining decisions; they are not a promise of particular interview questions or a job.

How long can I use the project?

The project page and checkout show the online access period for your selected plan. Access does not auto-renew. Downloaded source remains subject to its licence; future releases are not automatically included.

Review the Terms and No-Refund Policy before confirming access. All sales are final; Vectametric does not offer refunds.

This website is operated by VECTAMETRIC EDTECH (OPC) PRIVATE LIMITED, operating as Vectametric.

Corporate Identity Number (CIN): U85499KA2026OPC229822. GSTIN: 29AAMCV8281D1ZS. Registered office: RS NO/38/2A/1 BASTAND, ROAD MAHANTESH NAGAR, Ramdurg, Ramdurg, Belgaum- 591123, Karnataka.

Queries and grievances: Prajval Honnungar, Grievance Officer and Data Protection Contact.

Telephone: +91 94800 09310. Support: support@vectametric.com. Grievances: support@vectametric.com.

Copyright 2026 VECTAMETRIC EDTECH (OPC) PRIVATE LIMITED. All rights reserved.

Vectametric home · Roadmaps · Vecta IT Exams · Vecta Government Exams · Vecta Banking & Finance Exams · Vecta Entrance Exams · About us · Contact · Privacy Policy · Terms and Conditions · No-Refund Policy