Hooks: Run Something, Gate Something

Add a pre-upgrade gate that refuses a bad upgrade before any object changes, with a weight and a delete policy — then make it fail on purpose.

Skill labintermediate~45 minPro

What you'll do

  • ✓Attach a Job to a lifecycle point with a hook annotation
  • ✓Order hooks with weights and clean them up with a delete policy
  • ✓See that hooks are run rather than installed
  • ✓Stop an upgrade before it touches anything

Lab outline

  1. 01A gate
  2. 02Prove it stops

Before you start

  • Tests: One Kind That Renders, One That Runs

Every lab runs on a real machine of your own in the browser — no installs, nothing to clean up — and checks your work automatically as you go.

← All Helm labs

Your first machine is
8 seconds away.

Learn by doing on real machines — and give every AI agent one of its own.

Free forever · No credit card · Cancel anytime

Hooks: Run Something, Gate Something — Helm lab | Kube Labs