Bug 1174237 - Composite views allow promotions beyond what they should
Summary: Composite views allow promotions beyond what they should
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Content Views
Version: 6.0.6
Hardware: Unspecified
OS: Unspecified
medium
medium vote
Target Milestone: Unspecified
Assignee: Brad Buckingham
QA Contact: jcallaha
URL: http://projects.theforeman.org/issues...
Whiteboard:
Depends On:
Blocks: 1314394
TreeView+ depends on / blocked
 
Reported: 2014-12-15 13:16 UTC by Karl Abbott
Modified: 2019-08-12 15:58 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1314394 (view as bug list)
Environment:
Last Closed: 2016-07-27 09:12:08 UTC
Target Upstream Version:


Attachments (Terms of Use)
RHEL7 Test Build (3.34 MB, application/x-rpm)
2016-01-18 21:54 UTC, Mike McCune
no flags Details
RHEL6 Test Build (2.69 MB, application/x-rpm)
2016-01-18 22:10 UTC, Mike McCune
no flags Details


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1501 normal SHIPPED_LIVE Red Hat Satellite 6.2 Capsule and Server 2016-07-27 12:28:58 UTC

Description Karl Abbott 2014-12-15 13:16:17 UTC
If you have a content view (lets call it CV-A) that is in the Library environment. Now if I create a composite content view (lets call it CCV-A) and I add CV-A to this:

CCV-A
 |-- CV-A

I should NOT be able to promote CCV-A beyond the Library environment as the content views it is a member of are not at that level. I.e. I should not be able to promote CCV-A beyond the lowest environment of the content views.

Comment 1 RHEL Product and Program Management 2014-12-15 13:24:18 UTC
Since this issue was entered in Red Hat Bugzilla, the release flag has been
set to ? to ensure that it is properly evaluated for this release.

Comment 3 Eric Helms 2015-05-22 23:52:23 UTC
Karl,

If this were implemented as a toggle, would that suffice? I can envision that some users want to add view to a Composite and then promote the Composite expecting it to populate the environment with the views attached without the overhead of having to promote the individual views themselves since the Composite is it's own entity.

Comment 4 Andrew Schofield 2015-05-27 15:49:08 UTC
Hi Eric, a toggle should be sufficient so long as this can be set via the API / hammer too.

Comment 5 Bryan Kearney 2015-08-13 16:45:46 UTC
clearing the needinfo

Comment 6 Brad Buckingham 2016-01-07 20:21:05 UTC
Created redmine issue http://projects.theforeman.org/issues/13057 from this bug

Comment 7 Bryan Kearney 2016-01-07 21:06:37 UTC
Upstream bug component is WebUI

Comment 8 Brad Buckingham 2016-01-15 11:17:11 UTC
Upstream Katello PR: 

https://github.com/Katello/katello/pull/5698

Comment 9 Mike McCune 2016-01-18 21:51:34 UTC
Attached are some test RPMs for Satellite 6.1.5 (must be 6.1.5) to test the first iteration of this feature.

== INSTALLATION INSTRUCTIONS ==

1) Download ruby193-rubygem-katello packages from this BZ

2) Install (EL7 example):

# rpm -Uvh rpm -Uvh ruby193-rubygem-katello-2.2.0.80-1.el7sat.git.1.d748d52None.noarch.rpm 

3) Restart services:

# katello-service restart 

4) Login to Satellite webui and modify Administrator -> Settings -> Katello -> restrict_composite_view to 'true'

5) Attempt to publish a Composite Content View with Component Content View versions that do *not* exist in the target Environment.

Comment 10 Mike McCune 2016-01-18 21:54:42 UTC
Created attachment 1115985 [details]
RHEL7 Test Build

Comment 11 Mike McCune 2016-01-18 22:03:02 UTC
You should see an error message like this if the contained Content View is not available in the target env:

http://people.redhat.com/~mmccune/promote-error-message.png

Comment 12 Mike McCune 2016-01-18 22:10:37 UTC
Created attachment 1115990 [details]
RHEL6 Test Build

Comment 13 Andrew Schofield 2016-01-19 18:57:02 UTC
Thanks Mike. I should be able to take a look at this in the next day or so.

Comment 14 Andrew Schofield 2016-01-20 22:37:27 UTC
Hi Mike - the RHEL 6 RPM is a src rpm, can you add a non src as I can't build it:

# rpmbuild -bb --define "scl ruby193" rubygem-katello.spec
error: Failed build dependencies:
        ruby193-rubygems-devel is needed by ruby193-rubygem-katello-2.2.0.80-1.el6.git.1.d748d52None.noarch
        foreman-assets >= 1.7.0 is needed by ruby193-rubygem-katello-2.2.0.80-1.el6.git.1.d748d52None.noarch
        ruby193-rubygem-sqlite3 is needed by ruby193-rubygem-katello-2.2.0.80-1.el6.git.1.d748d52None.noarch
        ruby193-rubygem(uglifier) >= 1.0.3 is needed by ruby193-rubygem-katello-2.2.0.80-1.el6.git.1.d748d52None.noarch

(This is on 6.1.5)

Comment 15 Andrew Schofield 2016-01-24 13:41:27 UTC
Mike - ignore that. I ended up patching locally. I started testing late Friday so will have some feedback for you early in the week.

Comment 16 Mike McCune 2016-01-30 23:42:37 UTC
Andrew, thanks for patching manually. Looking forward to the feedback

Comment 17 Mike McCune 2016-01-30 23:59:18 UTC
Moving this to 6.1.8 (MAR-2016) while we await feedback from users.

Comment 20 jcallaha 2016-04-05 19:59:37 UTC
Verified in Satellite 6.2 Beta Snap 6 Compose 1. After changing the admin flag, and trying to promote past the lowest promoted level, you get this error message.

The action requested on this composite view cannot be performed until all of the component content view versions have been promoted to the target environment: QA. This restriction is optional and can be modified in the Administrator -> Settings page using the restrict_composite_view flag.

Comment 22 errata-xmlrpc 2016-07-27 09:12:08 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2016:1501


Note You need to log in before you can comment on or make changes to this bug.