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 1247611 - no (obvious?) way how to configure user data support for OpenStack image via hammer
Summary: no (obvious?) way how to configure user data support for OpenStack image via ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: API
Version: 6.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: Unspecified
Assignee: Stephen Benjamin
QA Contact: Jitendra Yejare
URL: http://projects.theforeman.org/issues...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-07-28 12:30 UTC by Jan Hutař
Modified: 2019-09-25 21:28 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-27 08:54:10 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 13852 0 None None None 2016-04-22 15:43:33 UTC
Red Hat Product Errata RHBA-2016:1500 0 normal SHIPPED_LIVE Red Hat Satellite 6.2 Base Libraries 2016-07-27 12:24:38 UTC

Description Jan Hutař 2015-07-28 12:30:11 UTC
Description of problem:
There is no (obvious?) way how to configure user data support for OpenStack image via hammer


Version-Release number of selected component (if applicable):
Satellite-6.1.0-RHEL-6-20150721.7-Satellite-x86_64


How reproducible:
always


Steps to Reproduce:
1. Configure OpenStack compute resource
2. Infrastructure -> Compute resources -> <your_cr> -> Images -> [New Image]
   (or edit existing one)
   Note that there is a "User data" checkbox
3. Now check hammer command for this functionality:

# hammer --username 'admin' --password 'changeme' compute-resource image create -h
Usage:
    hammer compute-resource image create [OPTIONS]

Options:
 --architecture ARCHITECTURE_NAME          Architecture name
 --architecture-id ARCHITECTURE_ID          
 --compute-resource COMPUTE_RESOURCE_NAME  Compute resource name
 --compute-resource-id COMPUTE_RESOURCE_ID  
 --name NAME                                
 --operatingsystem OPERATINGSYSTEM_TITLE   Operating system title
 --operatingsystem-id OPERATINGSYSTEM_ID    
 --username USERNAME                        
 --uuid UUID                                
 -h, --help                                print help
# hammer --username 'admin' --password 'changeme' compute-resource image update -h
Usage:
    hammer compute-resource image update [OPTIONS]

Options:
 --architecture ARCHITECTURE_NAME          Architecture name
 --architecture-id ARCHITECTURE_ID          
 --compute-resource COMPUTE_RESOURCE_NAME  Compute resource name
 --compute-resource-id COMPUTE_RESOURCE_ID  
 --id ID                                    
 --name NAME                               Name to search by
 --new-name NEW_NAME                        
 --operatingsystem OPERATINGSYSTEM_TITLE   Operating system title
 --operatingsystem-id OPERATINGSYSTEM_ID    
 --username USERNAME                        
 --uuid UUID                                
 -h, --help                                print help


Actual results:
There is no way how to configure user data support


Expected results:
There should be a way

Comment 1 Jan Hutař 2015-07-28 12:43:16 UTC
Workaround which seems to work (with image already created):

curl -k -u <user>:<pass> -X PUT -d '{ "user_data":true }' -H 'Accept: application/json' -H 'Content-Type: application/json' https://<fqdn>/api/v2/compute_resources/<cr_id>/images/<image_id>

Comment 3 Stephen Benjamin 2016-02-23 15:15:50 UTC
Created redmine issue http://projects.theforeman.org/issues/13852 from this bug

Comment 4 Bryan Kearney 2016-02-23 17:06:30 UTC
Upstream bug assigned to stbenjam

Comment 5 Bryan Kearney 2016-02-23 17:06:33 UTC
Upstream bug component is API

Comment 6 Bryan Kearney 2016-02-24 09:06:32 UTC
Moving to POST since upstream bug http://projects.theforeman.org/issues/13852 has been closed
-------------
Anonymous
Applied in changeset commit:1cd4a22df2b4a34ea8a03150b1bd406494587ed3.

Comment 9 Jitendra Yejare 2016-04-15 14:20:38 UTC
Verified this issue in Sat 6.2 snap 8.1

The issue is no more reproducible. I see --user-data option added while creating and updating an image.

Evidence:
# hammer compute-resource image create -h
Usage:
    hammer compute-resource image create [OPTIONS]

Options:
 --architecture ARCHITECTURE_NAME          Architecture name
 --architecture-id ARCHITECTURE_ID          
 --compute-resource COMPUTE_RESOURCE_NAME  Compute resource name
 --compute-resource-id COMPUTE_RESOURCE_ID  
 --name NAME                                
 --operatingsystem OPERATINGSYSTEM_TITLE   Operating system title
 --operatingsystem-id OPERATINGSYSTEM_ID    
 --user-data USER_DATA                     Whether or not the image supports user data
                                           One of true/false, yes/no, 1/0.
 --username USERNAME                        
 --uuid UUID                                
 -h, --help                                print help


# hammer compute-resource image update -h
Usage:
    hammer compute-resource image update [OPTIONS]

Options:
 --architecture ARCHITECTURE_NAME          Architecture name
 --architecture-id ARCHITECTURE_ID          
 --compute-resource COMPUTE_RESOURCE_NAME  Compute resource name
 --compute-resource-id COMPUTE_RESOURCE_ID  
 --id ID                                    
 --name NAME                               Name to search by
 --new-name NEW_NAME                        
 --operatingsystem OPERATINGSYSTEM_TITLE   Operating system title
 --operatingsystem-id OPERATINGSYSTEM_ID    
 --user-data USER_DATA                     Whether or not the image supports user data
                                           One of true/false, yes/no, 1/0.
 --username USERNAME                        
 --uuid UUID                                
 -h, --help                                print help

# hammer compute-resource image update --user-data 1 --id 1 --compute-resource-id 10
Image updated
# hammer compute-resource image update --user-data 0 --id 1 --compute-resource-id 10
Image updated

So moving this to verified.

Comment 11 errata-xmlrpc 2016-07-27 08:54:10 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:1500


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