16.3.2.2. Best practices when defining an RHACM-discovered VM
You can configure any VM in the cluster that is not an RHACM-managed application as an RHACM-discovered application. This includes VMs imported by using the Migration Toolkit for Virtualization (MTV), VMs created by using the OpenShift Container Platform web console, or VMs created by any other means, such as the CLI.
You can take several actions to improve your experience and chance of success when defining an RHACM-discovered VM.
- Protecting the VM when using MTV, the OpenShift Container Platform web console, or a custom VM
Because automatic labeling is not currently available, the application owner must manually label the components of the VM application when using MTV, the OpenShift Container Platform web console, or a custom VM.
After creating the VM, apply a common label to the following resources associated with the VM:
VirtualMachine,DataVolume,PersistentVolumeClaim,Service,Route,SecretandConfigMap. If the VM uses an instance type or preference, you must also label theControllerRevisioncopy of these objects referenced by the spec or status of the VM. Do not label virtual machine instances (VMIs) or pods; OpenShift Virtualization creates and manages these automatically.重要You must apply the common label to everything in the namespace that you want to protect, including objects that you added to the VM that are not listed here.
- Including more than the
VirtualMachineobject in the VM -
Working VMs typically also contain data volumes, persistent volume claims (PVCs), services, routes, secrets,
ConfigMapobjects, andVirtualMachineSnapshotobjects. - Including the VM as part of a larger logical application
- This includes other pod-based workloads and VMs.