Bug 1614927 - [RFE] Provide the ability to delete a lifecycle environment from the middle of an existing path
Summary: [RFE] Provide the ability to delete a lifecycle environment from the middle o...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Lifecycle Environments
Version: 6.3.2
Hardware: Unspecified
OS: Unspecified
unspecified
medium with 3 votes
Target Milestone: 6.5.0
Assignee: Justin Sherrill
QA Contact: vijsingh
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-08-10 18:32 UTC by Jason Dickerson
Modified: 2019-11-05 22:31 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-05-14 12:37:41 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
6.3 patch (1.17 KB, patch)
2018-09-05 03:15 UTC, Justin Sherrill
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 24596 0 'Normal' 'Closed' 'Provide the ability to delete a lifecycle environment from the middle of an existing path' 2019-11-15 07:30:06 UTC
Red Hat Product Errata RHSA-2019:1222 0 None None None 2019-05-14 12:37:52 UTC

Description Jason Dickerson 2018-08-10 18:32:12 UTC
1. Proposed title of this feature request  
  
[RFE] Provide the ability to delete a lifecycle environment from the middle of an existing path
  
2. What is the nature and description of the request?  
  
It is currently not possible to remove a lifecycle environment from the beginning or middle of an existing lifecycle environment path.  

For example if the current lifecycle environments (in order) are
Dev -> Test -> Staging -> Prod

and you wish to remove Staging such that the new list (in order) is
Dev -> Test -> Prod

it is not currently possible to achieve this

3. Why does the customer need this? (List the business requirements here) 

The customer supports various distinct environments in their organization.  Some environments needs change over time, and this would allow them to remove lifecycle environments that are deemed no longer necessary, by the different environment stakeholders.  
  
4. How would the customer like to achieve this? (List the functional requirements here)  
  
Make it possible, via the gui and hammer to remove a lifecycle environment from the path, in such a way as the previous environment is now linked instead to the latter environment.

6. For each functional requirement listed, specify how Red Hat and the customer can test to confirm the requirement is successfully implemented.  
  
Try to remove "Staging" as per the example in #2

7. Is there already an existing RFE upstream or in Red Hat Bugzilla?  
  
None found

8. Does the customer have any specific timeline dependencies and which release would they like to target (i.e. RHEL5, RHEL6)?  
  
ASAP

9. Is the sales team involved in this request and do they have any additional input?  
  
No

10. List any affected packages or components.  
  
Satellite 6.3.2
- API
- Hammer
- GUI

11. Would the customer be able to assist in testing this functionality if implemented?  

yes

Comment 2 Justin Sherrill 2018-08-13 13:40:14 UTC
Created redmine issue https://projects.theforeman.org/issues/24596 from this bug

Comment 3 Satellite Program 2018-08-13 14:18:20 UTC
Upstream bug assigned to jsherril

Comment 4 Satellite Program 2018-08-13 14:18:21 UTC
Upstream bug assigned to jsherril

Comment 5 Satellite Program 2018-08-20 14:17:53 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/24596 has been resolved.

Comment 6 Justin Sherrill 2018-09-05 03:15:49 UTC
Created attachment 1480959 [details]
6.3 patch

Comment 7 Justin Sherrill 2018-09-05 03:18:15 UTC
6.3 patch attached, simply apply the patch to your tfm-rubygem-katello installed directory, restart httpd and foreman-tasks and then remove the desired lifecycle environment with hammer.

Current 6.3 blocks UI elements from making this work in the UI and changing UI assets in production with just a patch is not possible currently, so you will have to use hammer.

Comment 10 vijsingh 2018-11-28 06:10:38 UTC
Verified:

@Satellite 6.5.0 Snap 5.0

steps:

+++++++++++++++++++++++++++++++++++++++++
hammer> lifecycle-environment list
---|---------|--------
ID | NAME    | PRIOR  
---|---------|--------
2  | DEV     | Library
1  | Library |        
8  | Prod    | Staging
7  | Staging | Test   
6  | Test    | DEV    
---|---------|--------


hammer> lifecycle-environment paths --organization-id 1
-----------------------------------------
LIFECYCLE PATH                           
-----------------------------------------
Library >> DEV >> Test >> Staging >> Prod
-----------------------------------------


hammer> lifecycle-environment delete --name Staging --organization-id 1
Environment deleted.

hammer> lifecycle-environment paths --organization-id 1 
------------------------------
LIFECYCLE PATH                
------------------------------
Library >> DEV >> Test >> Prod
------------------------------
hammer> 


hammer> lifecycle-environment list
---|---------|--------
ID | NAME    | PRIOR  
---|---------|--------
2  | DEV     | Library
1  | Library |        
8  | Prod    | Test   
6  | Test    | DEV    
---|---------|--------

+++++++++++++++++++++++++++++++++++++++++

Observation:
- Able to delete a lifecycle environment from the middle of an existing path.

Comment 12 Julian Curetti 2019-02-22 19:59:41 UTC
Can I implement this fix on a running Satellite 6.3.5 server?

Comment 14 errata-xmlrpc 2019-05-14 12:37:41 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/RHSA-2019:1222


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