Bug 1207044 - [RFE] Allow through API methods to render templates without configuring a host in build mode
Summary: [RFE] Allow through API methods to render templates without configuring a hos...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 6
Classification: Red Hat
Component: API
Version: Unspecified
Hardware: Unspecified
OS: Linux
unspecified
low vote
Target Milestone: Unspecified
Assignee: Shlomi Zadok
QA Contact: Stephen Benjamin
URL: http://projects.theforeman.org/issues...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-03-30 06:44 UTC by Sergio G.
Modified: 2019-09-26 17:38 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-27 08:50:08 UTC
Target Upstream Version:


Attachments (Terms of Use)


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

Description Sergio G. 2015-03-30 06:44:32 UTC
Description of problem:
If a host isn't in build mode, you cannot check if the kickstart template is rendered properly. Either you enable build mode and use http://sat6host/unattended/provision or you get an authentication cookie and use https://sat6host/unattended/provision?spoof=<hostname>. Both ways are tricky.


How reproducible:
Always


Steps to Reproduce:
1. Access to http://sat6host/unattended/provision from a host which is not in build mode and you won't get the template
2. Access to https://sat6.host/unattended/provision/?spoof=>hostname> and you will be redirected to login pages
3. No more methods to get it rendered


Expected results:
At least [1] should work, no matter the build status. Or it would be even better to have any API method to get it rendered.

Comment 1 RHEL Program Management 2015-03-30 07:03:28 UTC
Since this issue was entered in Red Hat Bugzilla, the release flag has been
set to ? to ensure that it is properly evaluated for this release.

Comment 3 Bryan Kearney 2015-09-01 17:19:06 UTC
Created redmine issue http://projects.theforeman.org/issues/11643 from this bug

Comment 5 Bryan Kearney 2015-11-04 11:05:13 UTC
Upstream bug assigned to szadok@redhat.com

Comment 6 Bryan Kearney 2015-11-19 15:05:43 UTC
Moving to POST since upstream bug http://projects.theforeman.org/issues/11643 has been closed
-------------
Shlomi Zadok
Applied in changeset commit:8a817cb209c9499663beb850f7eb8f1726da42ad.

Comment 7 Bryan Kearney 2015-11-20 16:31:45 UTC
Move to 6.2 since this will be contained in the next rebase.

Comment 11 Stephen Benjamin 2016-07-15 13:18:48 UTC
Verified in Satellite 6.2 Snap 20.1. There's now an API to preview templates:


[root@sat-snap-rhel7 ~]# curl -u admin:changeme -H "Content-Type:application/json" -H "Accept:application/json"  https://sat-snap-rhel7.example.com/api/v2/hosts/centos7.example.com/template/provision

{"template":"\n\ninstall\nurl --url...[snip]

Comment 13 errata-xmlrpc 2016-07-27 08:50:08 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.