#1037987 virt-p2v: The script virt-p2v-make-disk attempts to call the redhat package manager 'dnf' during build.

Package:
virt-p2v
Source:
virt-p2v
Description:
physical-to-virtual machine converter
Submitter:
Matthew Seddon
Date:
2023-06-15 08:03:04 UTC
Severity:
normal
#1037987#5
Date:
2023-06-15 07:59:53 UTC
From:
To:
Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?
   * What exactly did you do (or not do) that was effective (or
     ineffective)?
   * What was the outcome of this action?
   * What outcome did you expect instead?

*** End of the template - remove these template lines ***

Attempting to build a p2v iso to convert machines to vms.
When you run virt-p2v-make-disk -o ./p2v.iso it eventually throws an error:

```
[   6.8] Downloading: http://builder.libguestfs.org/debian-12.xz
[   7.7] Planning how to build this image
[   7.7] Uncompressing
[  13.2] Opening the new disk
[  17.7] Setting a random seed
virt-builder: warning: random seed could not be set for this type of guest
[  17.8] Uploading: /tmp/tmp.rs28NvEXtc/policy-rc.d to /usr/sbin/policy-rc.d
[  17.9] Setting the hostname: p2v.local
[  18.9] Running: hostname p2v.local
[  19.0] Running: dnf -y update --exclude=kernel\*
/bin/sh: 4: dnf: not found
virt-builder: error: dnf -y update --exclude=kernel\*: command exited with
an error

If reporting bugs, run virt-builder with debugging enabled and include the
complete output:

  virt-builder -v -x [...]
```

Manually changing the script to use 'apt-get update -y' instead of 'dnf update -y' allows the script to work.

```diff
249c249
<     --run-command 'dnf -y update --exclude=kernel\*'            \
---
```