From 867e9946b5f9d40cb0ecf4f74ee2563462dab777 Mon Sep 17 00:00:00 2001 From: Lee Yarwood Date: Mon, 25 Mar 2024 14:20:22 +0000 Subject: [PATCH] instancetype: Add basic expand-spec docs Adds missing expand-spec documentation for both the subresource API and virtctl command. Signed-off-by: Lee Yarwood --- docs/virtual_machines/instancetypes.md | 119 +++++++++++++++++++++++++ 1 file changed, 119 insertions(+) diff --git a/docs/virtual_machines/instancetypes.md b/docs/virtual_machines/instancetypes.md index df0174f62..75db1b32d 100644 --- a/docs/virtual_machines/instancetypes.md +++ b/docs/virtual_machines/instancetypes.md @@ -309,6 +309,125 @@ $ kubectl get vmi/vm-cirros-csmall -o json | jq .spec.domain.cpu } ``` +## expand-spec + +A VM subresource API and `virtctl` subcommand are provided to allow users to obtain a copy of their existing or yet to be defined VM with any referenced instance types or preferences expanded within the core spec of the VM. + +For example, given the following simple VM using an instance type we can use the API or `virtctl` command to obtain an expanded copy of the VM, using `diff` to highlight the differences between the original and expanded VM: + +```yaml +$ kubectl apply -f - <