Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -314,15 +314,15 @@ public class LibvirtComputingResource extends ServerResourceBase implements Serv

public static final String TUNGSTEN_PATH = "scripts/vm/network/tungsten";

public static final String INSTANCE_CONVERSION_SUPPORTED_CHECK_CMD = "virt-v2v --version";
public static final String INSTANCE_CONVERSION_SUPPORTED_CHECK_CMD = "\"virt-v2v --version\"";
// virt-v2v --version => sample output: virt-v2v 1.42.0rhel=8,release=22.module+el8.10.0+1590+a67ab969
public static final String OVF_EXPORT_SUPPORTED_CHECK_CMD = "ovftool --version";
public static final String OVF_EXPORT_SUPPORTED_CHECK_CMD = "\"ovftool --version\"";
// ovftool --version => sample output: VMware ovftool 4.6.0 (build-21452615)
public static final String OVF_EXPORT_TOOl_GET_VERSION_CMD = "ovftool --version | awk '{print $3}'";
public static final String OVF_EXPORT_TOOl_GET_VERSION_CMD = "\"ovftool --version | awk '{print $3}'\"";

public static final String WINDOWS_GUEST_CONVERSION_SUPPORTED_CHECK_CMD = "rpm -qa | grep -i virtio-win";
public static final String UBUNTU_WINDOWS_GUEST_CONVERSION_SUPPORTED_CHECK_CMD = "dpkg -l virtio-win";
public static final String UBUNTU_NBDKIT_PKG_CHECK_CMD = "dpkg -l nbdkit";
public static final String WINDOWS_GUEST_CONVERSION_SUPPORTED_CHECK_CMD = "\"rpm -qa | grep -i virtio-win\"";
public static final String UBUNTU_WINDOWS_GUEST_CONVERSION_SUPPORTED_CHECK_CMD = "\"dpkg -l virtio-win\"";
public static final String UBUNTU_NBDKIT_PKG_CHECK_CMD = "\"dpkg -l nbdkit\"";
Comment on lines +317 to +325
Copy link
Preview

Copilot AI Sep 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding quotes around entire commands may cause issues depending on how these constants are used. If these strings are passed to ProcessBuilder or similar APIs that handle arguments separately, the quotes will be interpreted literally rather than as shell quoting. Consider reviewing how these constants are consumed to ensure the quoting approach is appropriate for the execution method.

Copilot uses AI. Check for mistakes.

Comment on lines +317 to +325
Copy link
Preview

Copilot AI Sep 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding quotes around entire commands may cause issues depending on how these constants are used. If these strings are passed to ProcessBuilder or similar APIs that handle arguments separately, the quotes will be interpreted literally rather than as shell quoting. Consider reviewing how these constants are consumed to ensure the quoting approach is appropriate for the execution method.

Copilot uses AI. Check for mistakes.

Comment on lines +317 to +325
Copy link
Preview

Copilot AI Sep 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding quotes around entire commands may cause issues depending on how these constants are used. If these strings are passed to ProcessBuilder or similar APIs that handle arguments separately, the quotes will be interpreted literally rather than as shell quoting. Consider reviewing how these constants are consumed to ensure the quoting approach is appropriate for the execution method.

Copilot uses AI. Check for mistakes.

Comment on lines +323 to +325
Copy link
Preview

Copilot AI Sep 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding quotes around entire commands may cause issues depending on how these constants are used. If these strings are passed to ProcessBuilder or similar APIs that handle arguments separately, the quotes will be interpreted literally rather than as shell quoting. Consider reviewing how these constants are consumed to ensure the quoting approach is appropriate for the execution method.

Suggested change
public static final String WINDOWS_GUEST_CONVERSION_SUPPORTED_CHECK_CMD = "\"rpm -qa | grep -i virtio-win\"";
public static final String UBUNTU_WINDOWS_GUEST_CONVERSION_SUPPORTED_CHECK_CMD = "\"dpkg -l virtio-win\"";
public static final String UBUNTU_NBDKIT_PKG_CHECK_CMD = "\"dpkg -l nbdkit\"";
public static final String UBUNTU_NBDKIT_PKG_CHECK_CMD = "dpkg -l nbdkit";

Copilot uses AI. Check for mistakes.


public static final int LIBVIRT_CGROUP_CPU_SHARES_MIN = 2;
public static final int LIBVIRT_CGROUP_CPU_SHARES_MAX = 262144;
Expand Down
Loading