Bug 1176269

Summary: rhel-common element attempts to install rhel-7-server on RHEL 6 image
Product: [Community] RDO Reporter: Elise Gafford <egafford>
Component: distributionAssignee: Ben Nemec <bnemec>
Status: CLOSED NOTABUG QA Contact: yeylon <yeylon>
Severity: high Docs Contact:
Priority: unspecified    
Version: JunoCC: srevivo, ukalifon, yeylon
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-07-06 21:32:51 UTC 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 Elise Gafford 2014-12-19 22:20:11 UTC
Description of problem:

It is necessary for RHOS 6 Sahara's intended usage flow for RHEL 6 images to be built in RHEL 7 using diskimage-builder. However, the current rhel-common element's handling of repository injection does not allow the default rhel-7-server repo to be removed. With modifications to the codebase to remove this repo, RHEL 6 images can be successfully built and subscribed.

Version-Release number of selected component (if applicable):

diskimage-builder-0.1.34-18


How reproducible:
100%

Steps to Reproduce:
1. Download current official RHEL 6 guest image qcow2.
2. Specify (substituting appropriate paths):
   export REG_REPOS="rhel-6-server-rpms rhel-6-server-optional-rpms"
   export BASE_IMAGE_FILE=rhel-guest-image-6.6-20140926.0.x86_64.qcow2
   export DIB_CLOUD_IMAGES=file:///root
3. Run:
   disk-image-create "rhel"

Actual results:

Repository rhel-7-server cannot be attached to RHEL 6 instance (appropriate, but unavoidable in current codebase.)

Expected results:

No attempt to attach rhel-7-server repository is made.

Additional info:

Bug logged upstream; code pushed to fix said bug; review at:
https://review.openstack.org/#/c/143182/

Comment 2 Elise Gafford 2015-07-06 21:32:51 UTC
This is WAI for the element in question, which has two separate code paths, governed by two separate sets of env vars, for RHEL 6 and RHEL 7. While this is an instance of a pretty severe antipattern, it's not technically a bug. Closing.