HyOps On-Prem Template to VM Smoke¶
-
Purpose: Validate the core on-prem chain end-to-end in one environment. Owner: Platform engineering
-
Trigger: Driver/validator changes, module refactors, release candidate checks
- Impact: Confirms template-image and platform-vm behaviors before broader blueprint rollout
-
Severity: P2 Pre-reqs: HyOps runtime initialized, Proxmox reachable, vault password source available.
-
Rollback strategy: Script auto-destroys the temporary smoke VM by default; template-image rollback remains module-level
destroywith matching inputs.
Context¶
This smoke gate verifies:
hyops init proxmoxhyops apply core/onprem/template-image(Linux)hyops apply core/onprem/template-image(Windows)hyops apply platform/onprem/platform-vmviatemplate_state_refusing an isolated state instancehyops destroy platform/onprem/platform-vm(automatic cleanup, unless--keep-vm)
It is implemented as a single script:
hybridops-core/tools/smoke/hyops-onprem-template-vm-smoke.sh
Preconditions and safety checks¶
- Installed
hyops(viainstall.sh) can be run from any working directory. - Source-checkout usage should export
HYOPS_CORE_ROOT=/path/to/hybridops-core. - Confirm target environment (
dev,staging, etc.) is correct. - Confirm Proxmox API and SSH reachability from the runner.
- Confirm sufficient datastore capacity for template rebuilds.
- Confirm no change-freeze restrictions for VM/template lifecycle operations.
Steps¶
-
Run smoke chain
# If running from a source checkout: # ./tools/smoke/hyops-onprem-template-vm-smoke.sh ... # # If running from an installed HyOps prefix (default): "$HOME/.hybridops/core/app/tools/smoke/hyops-onprem-template-vm-smoke.sh" \ --env dev \ --proxmox-ip <proxmox-ip> \ # --vault-password-command <absolute-path-to-password-command> -
Optional flags
# Skip init (when target is already initialized) ./tools/smoke/hyops-onprem-template-vm-smoke.sh \ --env dev \ --skip-init \ --proxmox-ip <proxmox-ip> # Skip Windows build for faster checks ./tools/smoke/hyops-onprem-template-vm-smoke.sh \ --env dev \ --proxmox-ip <proxmox-ip> \ --skip-windows # Keep the temporary VM for manual inspection (disables automatic cleanup) ./tools/smoke/hyops-onprem-template-vm-smoke.sh \ --env dev \ --proxmox-ip <proxmox-ip> \ --keep-vm
Verification¶
Check module state outputs:
$HOME/.hybridops/envs/dev/state/modules/core__onprem__template-image/latest.json$HOME/.hybridops/envs/dev/state/modules/platform__onprem__platform-vm/instances/template_smoke_vm.json
Confirm:
- Both states report
status: ok. - Template state contains
template_key,template_name,template_vm_id. - VM state (instance slot) contains
vm_ids/vm_keys/vm_namesand references deployed VM outputs. vm_keysare the logical HyOps names;vm_namesare the physical names created on the target platform.- Script output includes
smoke_verify=okplus resolved VM details (smoke_vm_name,smoke_vm_id,smoke_vm_ip_present, andsmoke_vm_ipwhen available).
Evidence root:
$HOME/.hybridops/envs/dev/logs/module/
The script also prints:
scratch(generated overlays used for the run)template_statevm_statesmoke_verify/smoke_vm_*verification fieldsmodule_logs
Post-actions and clean-up¶
- The script destroys the temporary smoke VM automatically unless
--keep-vmis used. - If
--keep-vmwas used, destroy the temporary VM with the same generated inputs and--state-instanceshown in the script output and runtime logs. - Archive runtime log paths in the release or change ticket.
- If smoke fails, block blueprint-level rollout until root cause is resolved.
References¶
- Runbook - Build Proxmox VM Templates (HyOps)
- Runbook - HyOps init proxmox
- HOWTO - Build and Rebuild Proxmox Templates with HyOps
- ADR-0016 - Packer + Cloud-Init VM templates