Lab 03: Provisioning After Boot
Use Yeast provisioning to install packages, copy files, and run shell commands after the VM is reachable.
You will learn:
- what
provision.packagesdoes - what
provision.filesdoes - what
provision.shelldoes - how top-level provisioning applies to instances
- when to use
yeast provision - when to use
yeast up --reprovisionoryeast up --no-provision
What You Will Build
yeast-lab-03/
└── web VM
├── Ubuntu 24.04
├── Caddy installed
├── static index.html copied
└── Caddy restarted by shell commands
Before You Start
Run:
Step 1: Create The Project
Inspect the provisioning config:
The template uses top-level provision, which applies to the web instance.
Step 2: Start The VM
After SSH becomes ready, Yeast installs packages, copies files, and runs shell commands from yeast.yaml.
Step 3: Verify Provisioning
Expected output:
Check the copied file:
Step 4: Read Logs
Use logs when the VM starts but something inside the boot or runtime path looks wrong.
Step 5: Rerun Provisioning On A Running VM
Use this when the VM is already running and you want to reapply provisioning without recreating the VM.
Step 6: Compare Provisioning Flags
Force provisioning during up:
Skip provisioning during up:
These flags are useful when debugging provisioning separately from VM startup.
Clean Up
What You Learned
Cloud-init prepares access. Provisioning turns a reachable VM into the machine you want.
Provisioning is Yeast's built-in way to make small, repeatable setup steps part of the project.
Next Lab
Continue with Status, Logs, Inspect, JSON.