Bug 2208340

Summary: rhsm kickstart command does not work with livemedia-creator
Product: Red Hat Enterprise Linux 9 Reporter: Brian Lane <bcl>
Component: loraxAssignee: Brian Lane <bcl>
Status: POST --- QA Contact: Release Test Team <release-test-team>
Severity: high Docs Contact:
Priority: unspecified    
Version: 9.2CC: jstodola
Target Milestone: rcKeywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Brian Lane 2023-05-18 16:06:26 UTC
Description of problem:
When using the rhsm kickstart command with livemedia-creator on RHEL the installation is terminated before it installs the packages.

The problem is that Anaconda tries to mount the repositories from the cdrom/dvd before trying the CDN specified by the rhsm command. livemedia-creator sees the error and assumes the installation has failed so it kills the VM before Anaconda has fallen back to the CDN source.

Version-Release number of selected component (if applicable):
lorax-34.9.23-1
anaconda-38.23.4-2

How reproducible:
Always

Steps to Reproduce:
1. Make a kickstart using rhsm for the content
2. Run livemedia-creator with the kickstart
3. Observe that the installation fails after an error

    18:10:59,811 ERR anaconda:packaging: base repo (CDROM/file:///run/install/sources/mount-0000-cdrom) not valid -- removing it

Upstream patch for lorax to work around this:
https://github.com/weldr/lorax/pull/1325

(Anaconda should probably also be changed to more intelligently select the base repo when using kickstart and rhsm but this should work around it for now).