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 1875314 - [RFE] Cannot delete content view due to associated environments
Summary: [RFE] Cannot delete content view due to associated environments
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Ansible Collection
Version: 6.7.0
Hardware: x86_64
OS: Linux
high
high
Target Milestone: 6.9.0
Assignee: Evgeni Golov
QA Contact: Peter Ondrejka
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-09-03 10:10 UTC by Sam Wachira
Modified: 2023-12-15 19:09 UTC (History)
4 users (show)

Fixed In Version: ansible-collection-redhat-satellite-1.3.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-04-21 13:17:42 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github theforeman foreman-ansible-modules pull 952 0 None closed remove CVs from lifecycle environments before deleting them 2021-02-08 08:14:26 UTC
Red Hat Product Errata RHSA-2021:1313 0 None None None 2021-04-21 13:17:58 UTC

Comment 1 Sean O'Keeffe 2020-09-08 15:38:46 UTC
You should be able to use the lifecycle_environment modules to first remove the Lifecycle Environment

https://cloud.redhat.com/ansible/automation-hub/redhat/satellite/content/module/lifecycle_environment

Comment 2 Evgeni Golov 2020-09-09 06:14:52 UTC
(In reply to Sean O'Keeffe from comment #1)
> You should be able to use the lifecycle_environment modules to first remove
> the Lifecycle Environment
> 
> https://cloud.redhat.com/ansible/automation-hub/redhat/satellite/content/
> module/lifecycle_environment

No, you can't

Comment 3 Evgeni Golov 2020-09-14 09:33:21 UTC
Just to make it more explicit:

Today, you *CAN* delete a CV version using the content_view_version module, *IF* that version is not part of any Lifecycle Environment at that moment.
So if you have the LCEs Library, Test and Prod, something like this would work:

- name: "Ensure CV version 2.0 is in all LCEs"
  content_view_version:
    content_view: "CV 1"
    version: "2.0"
    lifecycle_environments:
      - Library
      - Test
      - Pre Prod

- name: "Delete CV version 1"
  content_view_version:
    content_view: "CV 1"
    version: "1.0"
    state: absent

However, you can't completely delete a CV right now.

Comment 5 Peter Ondrejka 2020-12-10 16:52:15 UTC
Verified on Satellite 6.9 snap 5, CV is removed as expected even if published in a LCE

Comment 8 errata-xmlrpc 2021-04-21 13:17:42 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 (Moderate: Satellite 6.9 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-2021:1313


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