Configuration file vm.yaml
The vm.yaml file is a file used to define a Virtual Machine that is responsible for configuring a Virtual Machine (VM) running in Kubernetes, such as through KubeVirt. It contains information related to VM specifications, such as CPU, memory, and the type of operating system used. This ensures that the VM is treated as one of the Kubernetes objects that can be controlled and managed like a Pod. In the terminal/command prompt that you use, run the syntax according to the operating system that your computer is using.
Windows
If you are using a Windows operating system, you can use Notepad++ or the text editor your computer uses.
Linux
If you are using the Linux operating system, use the following command.
With GPU
If you want use GPU in your VM you can add source code for the vm.yaml file.
Without GPU
If you don't want add GPU in your VM, you can add this source code for the vm.yaml file.
The following is an explanation of the source code that will be used, so that it adapts to your needs.
Metadata
In the source code section in the metadata section there is a name and namespace. In the name and namespace are the identities used to label the machine to be used. Adjust the name with the name of the machine used, while in the namespace section adjust it with the namespace in the vcluster used in the Deka GPU Portal Service.
Specs
In the source code section in the specs section of the vm.yaml file is used to define the specifications of the VM to be used. So there are some source codes that must be adjusted.
In the spec section there are domains and devices. In the domain section there are resources that regulate the minimum and maximum that can be used by the VM, while in the device section if you are using a GPU you need to add the source code below.
Here is a comparison of source code using GPU and without GPU.
In the Volumes section there is a configuration for containerdisk and cloudinitdisk. For the name in the containerdisk in the dataVolumes section, use the name entered in the name in the metadata section in the dv.yaml file. For the name in the cloudinitdisk in the password section, adjust the password that will be used to access the VM. In this line to update the password that will be used, you simply change the sentence after "root:". Because "root" is the username that you will use to log in to the VM.
Use this command syntax to save the changes made to the vm.yaml file.
Last updated