Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "Add TPM" VM action #1796

Merged
merged 4 commits into from
Nov 5, 2024
Merged

Commits on Nov 4, 2024

  1. Show failed TPM addition errors

    Don't just sweep them under the rug -- this is actually important for
    moving to EFI firmware. It'll become even more important with an
    explicit "Add TPM" action that we'll add in the next step.
    
    Unskip `testConfigureBeforeInstallBiosTPM` on RHEL 8 and Arch, and explicitly
    check how it fails there.
    martinpitt committed Nov 4, 2024
    Configuration menu
    Copy the full SHA
    6afc9ba View commit details
    Browse the repository at this point in the history
  2. Add "Add TPM" VM action

    This helps with upgrading old VMs to a newer guest OS that requires a
    TPM, such as Windows 11.
    
    Replace the virt-xml hackery in `testConfigureBeforeInstallBiosTPM` with
    this corresponding new UI action. Add tests for adding TPM to both a
    shutdown and a running VM.
    
    Ignore swtpm AppArmor denial message in the test. We already had this in
    `testConfigureBeforeInstallBiosTPM`, apply it to that new one as well,
    and add/update the downstream bug reference. This got fixed in Ubuntu
    (https://launchpad.net/bugs/1968187) but not in Debian yet.
    
    Skip that test for RHEL 8 and Arch, where adding a TPM is known to not
    work (same as in `testConfigureBeforeInstall()`).
    
    Co-Authored-By: Martin Pitt <[email protected]>
    Shotaro-Kawaguchi and martinpitt committed Nov 4, 2024
    Configuration menu
    Copy the full SHA
    fd31fcd View commit details
    Browse the repository at this point in the history
  3. test: Add AppArmor message ignore to testConfigureBeforeInstall

    This also checks TPM, so use the same ignore as in
    testConfigureBeforeInstallBiosTPM.
    
    This is a race condition/flake.
    martinpitt committed Nov 4, 2024
    Configuration menu
    Copy the full SHA
    0624fcf View commit details
    Browse the repository at this point in the history
  4. Show VM start failure as console message

    We want to write a precise naughty for some startup failures like
    cockpit-project/bots#6792 . For that we need
    the message on the console, not just on the UI.
    
    It also makes human debugging easier.
    martinpitt committed Nov 4, 2024
    Configuration menu
    Copy the full SHA
    15cda68 View commit details
    Browse the repository at this point in the history