Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 1258323

Summary: Bootiso API not working
Product: Red Hat Satellite Reporter: Benjamin <bkruell>
Component: APIAssignee: Lukas Zapletal <lzap>
Status: CLOSED NOTABUG QA Contact: Katello QA List <katello-qa-list>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.1.0CC: bbuckingham, cwelton, smeyer
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-01-29 10:29:35 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:

Description Benjamin 2015-08-31 06:01:46 UTC
Description of problem:
The bootdisk API calls do not work:
GET /bootdisk/api 	             Boot disks
GET /bootdisk/api/generic 	     Download generic image
GET /bootdisk/api/hosts/:host_id     Download host image

It is working to create a bootdisk for hosts through the webinterface but when the APi is being used no matter which of the call above is used.


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

How reproducible:
#host specific:
curl -sS -k -u ${USER}:${PASS} https://${SATELLITE_SERVER}/bootdisk/api/hosts/:${HOST_ID}
#generic:
curl -sS -k -u ${USER}:${PASS} https://${SATELLITE_SERVER}/bootdisk/api/generic


Actual results:
Error URL unknown

Expected results:
Download the ISO.

Comment 1 Benjamin 2015-08-31 06:03:07 UTC
curl -sS -k -u ${USER}:${PASS} https://${SATELLITE_SERVER}/bootdisk/api/hosts/${HOST_ID}

Comment 3 Stefan Meyer 2016-01-29 10:29:35 UTC
It works if you set the content type in the curl command:
-H "Accept: version=2,application/json" -H "Content-Type: application/json"

curl -o bootdisk_generic.iso -sS -k -u ${USER}:${PASS} -H "Accept: version=2,application/json" -H "Content-Type: application/json" https://${SATELLITE_SERVER}/bootdisk/api/generic

curl -o ${HOSTNAME}.iso -sS -k -u ${USER}:${PASS} -H "Accept: version=2,application/json" -H "Content-Type: application/json" https://${SATELLITE_SERVER}/bootdisk/api/hosts/${HOSTNAME}