<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
On 01/13/2012 11:09 AM, Petr Vobornik wrote:
<blockquote cite="mid:4F105747.5050409@redhat.com" type="cite">I
have created a helper tool (script) for updating
install/ui/test/data/*.json files which are used for offline
presentation of FreeIPA Web UI. So I'm sharing it as it might be
useful for others.
<br>
<br>
Main purpose:
<br>
* updating ipa_init*.json files (should replace old not-working
bash script)
<br>
* creating new *.json files when implementing new UI functionality
<br>
* updating existing files when modifying UI.
<br>
<br>
Pros:
<br>
* command definition is very easy - just copy it from Chromium or
other developer tool a paste it into the code (with little text
around).
<br>
<br>
How it works:
<br>
* user can define commands - concrete command with name, arguments
and options
<br>
<br>
then it can
<br>
* call the command (using curl) and get JSON response from IPA
server
<br>
* modify the response
<br>
* save response to file
<br>
* or print response to console
<br>
<br>
Current modification of response:
<br>
* replaces dns, domains, hostname from IPA server's to
dev.example.com
<br>
* removes principal and version (no more various GIT versions)
<br>
* removes trailing whitespaces
<br>
<br>
Additional functionality:
<br>
* possibility to define command groups
<br>
* can execute multiple commands or groups
<br>
* list defined commands and groups
<br>
<br>
Common usage:
<br>
ipa-json.py -v -d -s --methods method_name method_2_name
<br>
<br>
or type 'ipa-json.py -h' for more options
<br>
<br>
note: command and method mean basically the same, the naming
should be united...
<br>
<br>
Possible future enhancements:
<br>
* add kerberos authentication
<br>
* split definition of methods, code and configuration to multiple
files
<br>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Freeipa-devel mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Freeipa-devel@redhat.com">Freeipa-devel@redhat.com</a>
<a class="moz-txt-link-freetext" href="https://www.redhat.com/mailman/listinfo/freeipa-devel">https://www.redhat.com/mailman/listinfo/freeipa-devel</a></pre>
</blockquote>
<br>
Petr,<br>
<br>
Kerberos should be pretty straight forward. For command line curl
it is<br>
<br>
--negotiate -u --delegation always<br>
<br>
so you should be able to add those options right before
c.setopt(pycurl.URL, url)<br>
<br>
<br>
<br>
<div class="line alt1">
<table>
<tbody>
<tr>
<td class="content"><br>
</td>
</tr>
</tbody>
</table>
</div>
<div class="line alt2">
<table>
<tbody>
<tr>
<td class="number"><code></code><br>
</td>
<td class="content"><code class="spaces"></code><br>
</td>
</tr>
</tbody>
</table>
</div>
<br>
<br>
<br>
<br>
<br>
</body>
</html>