Bug 1108779

Summary: hammer content-host create does not work with lifecycle-env name
Product: Red Hat Satellite Reporter: Kedar Bidarkar <kbidarka>
Component: HammerAssignee: Dustin Tsang <dtsang>
Status: CLOSED CURRENTRELEASE QA Contact: Tazim Kolhar <tkolhar>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.0.3CC: adprice, cwelton, dtsang, jmontleo, mbacovsk, mmccune, tkolhar
Target Milestone: Unspecified   
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
URL: http://projects.theforeman.org/issues/5697
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-07-02 14:07:21 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:
Attachments:
Description Flags
the bedug info for the above command none

Description Kedar Bidarkar 2014-06-12 14:34:31 UTC
Description of problem:
similar to bug https://bugzilla.redhat.com/show_bug.cgi?id=1107319

the above bug was fixed but the bug update on comment#3 still exists.

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

How reproducible:
always

Steps to Reproduce:
1.  hammer -v -d content-host create --name="test_host" --environment='Library' --content-view-id=2 --organization-id 1 
2.
3.

Actual results:
unable to create a content-host and we get a message 

# hammer content-host create --name="test_host" --environment='Library' --content-view-id=2 --organization-id 1 
Could not create content host:
  Error: environment found more than once


Expected results:

content-host needs to get create successfull with the lifecycle-env as name.

Additional info:

Comment 1 Kedar Bidarkar 2014-06-12 14:36:23 UTC
Created attachment 908176 [details]
the bedug info for the above command

Comment 3 Dustin Tsang 2014-06-17 16:08:34 UTC
dupe of redmine issue http://projects.theforeman.org/issues/5697

Comment 4 Dustin Tsang 2014-06-17 17:51:44 UTC
The pull requests that fix this issue are:
https://github.com/Katello/katello/pull/4244
https://github.com/Katello/hammer-cli-katello/pull/189

Comment 7 Tazim Kolhar 2014-06-19 07:19:48 UTC
# hammer content-host create --name test_host --environment Library --content-view-id 50 --organization-id 1
Name:                  test_host
ID:                    07a1dad1-0a19-454a-b335-2df6620c3f0b
Description:           Initial Registration Params
Location:              None
Lifecycle Environment: Library
Content View:          cv1
Entitlement Status:    valid
Release Version:       
Autoheal:              true

Content host created

Comment 8 Bryan Kearney 2014-07-02 14:07:21 UTC
This was delivered with 6.0.3, which is the Satellite 6 Beta.