Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2153523 - Promoting a composite content view to environment with registry name as "<%= lifecycle_environment.label %>/<%= repository.name %>" on Red Hat Satellite 6 fails with "'undefined method '#label' for NilClass::Jail (NilClass)'"
Summary: Promoting a composite content view to environment with registry name as "<%= ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Content Views
Version: 6.11.4
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: 6.15.0
Assignee: Quinn James
QA Contact: Sam Bible
URL:
Whiteboard:
: 2237999 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-12-14 17:13 UTC by soham
Modified: 2024-05-16 08:23 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2266144 (view as bug list)
Environment:
Last Closed: 2024-04-23 17:12:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 36776 0 Normal Closed Promoting a composite content view to environment with registry name as "<%= lifecycle_environment.label %>/<%= reposito... 2023-10-02 16:36:53 UTC
Red Hat Issue Tracker SAT-18728 0 None None None 2023-06-30 12:05:35 UTC
Red Hat Product Errata RHSA-2024:2010 0 None None None 2024-04-23 17:12:56 UTC

Description soham 2022-12-14 17:13:06 UTC
Description of problem:
Promoting a composite content view to environment with registry name as "<%= lifecycle_environment.label %>/<%= repository.name %>" on Red Hat Satellite 6 fails with "'undefined method '#label' for NilClass::Jail (NilClass)'"

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


How reproducible:
Always


Steps to Reproduce:
Create product

# hammer product create --description "Product Busybox Container" --name Product_Busybox_Container --label "Product_Busybox_Container" --organization myorg
Create repository and sync to source

# hammer repository create \
  --content-type "docker" \
  --organization myorg \
  --product "Product_Busybox_Container" \
  --url "https://registry-1.docker.io" \
  --name "library/busybox" \
  --docker-upstream-name "library/busybox" \
  --label "library_busybox" \
  --include-tags "stable, 1.35.0"
 
# hammer repository synchronize --name "library/busybox" --product "Product_Busybox_Container" --organization myorg

Create content view

# hammer repository list --product Product_Busybox_Container --organization myorg
# hammer content-view create --label ContentView_Busybox --name ContentView_Busybox --organization-label myorg --repository-ids 1225
Replace 1225 with the id from above command

Content view creation

# hammer content-view publish --organization myorg --name ContentView_Busybox


Now assign this created content-view to a composite-content-view

Create an environment test with registry name as "<%= lifecycle_environment.label %>/<%= repository.name %>"

promote composite-content-view to test environment

        ERROR: 'undefined method '#label' for NilClass::Jail (NilClass)'

Comment 1 Brad Buckingham 2022-12-15 15:19:45 UTC
Can the full stack trace from the production.log?   Thanks!

Comment 4 Quinn James 2023-09-25 15:19:28 UTC
Created redmine issue https://projects.theforeman.org/issues/36776 from this bug

Comment 5 Bryan Kearney 2023-10-02 16:02:14 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/36776 has been resolved.

Comment 6 Quinn James 2023-10-27 15:52:48 UTC
*** Bug 2237999 has been marked as a duplicate of this bug. ***

Comment 8 Sam Bible 2024-01-23 16:38:02 UTC
Verified on 6.15 - Snap 5

Steps to Verify:
1.Create a product:
 - hammer product create --description "Product Busybox Container" --name Product_Busybox_Container --label "Product_Busybox_Container" --organization myorg
2.Create a repository and sync it:
 - hammer repository create \
   --content-type "docker" \
   --organization myorg \
   --product "Product_Busybox_Container" \
   --url "https://registry-1.docker.io/" \
   --name "library/busybox" \
   --docker-upstream-name "library/busybox" \
   --label "library_busybox" \
   --include-tags "stable, 1.35.0"
 - hammer repository synchronize --name "library/busybox" --product "Product_Busybox_Container" --organization myorg (For future reproducers, you might need to find a different registry for use here, docker.io refuses connection often)
3. Create a content view with this repo and publish it:
 - hammer content-view create --label ContentView_Busybox --name ContentView_Busybox --organization-label myorg --repository-ids <repo_id>
 - hammer content-view publish --organization myorg --name ContentView_Busybox
4. Create a CCV
5. Add the CV to this composite CV.
6. Create an LCE. Modify the registry name pattern to <%= repository.name %>.
7. Create another LCE. Modify the registry name pattern to <%= lifecycle_environment.label %>/<%= repository.name %>
8. Promote the CV to the first LCE.
9. Promote the CV to the second LCE.

Expected Results:
The CCV can successfully be promoted to both LCEs without error. 

Actual Results:
The CCV can successfully be promoted to both LCEs without error.

Comment 11 errata-xmlrpc 2024-04-23 17:12:54 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 (Important: Satellite 6.15.0 release), 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/RHSA-2024:2010


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