<p dir="ltr">I got the use case of ovirt.js. But I don't think so it can be used in my case. I have to instead use CGI/php. My aim is to run the command from the rhevm manager bash prompt with dynamic attributes and then returns the success/failure result.</p>
<p dir="ltr">E.g `rhevmcommand -lrt -p password `</p>
<p dir="ltr">Rhevmcommand is written in bash script, which internally calls REST api using curl.</p>
<p dir="ltr">Password is similar that of rhevm manager database.</p>
<p dir="ltr">Now I want something like<br>
<snip><br>
Var result=`rhevmcommand -lrt`<br>
<> in HTML/java/...web UI.<br></p>
<p dir="ltr">-Nikita<br>
</p>
<div class="gmail_quote">On 06/11/2014 6:29 pm, "Vojtech Szocs" <<a href="mailto:vszocs@redhat.com">vszocs@redhat.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
<br>
----- Original Message -----<br>
> From: "Itamar Heim" <<a href="mailto:iheim@redhat.com">iheim@redhat.com</a>><br>
> To: "Nikita Kodkani" <<a href="mailto:nikita.kodkani@gmail.com">nikita.kodkani@gmail.com</a>><br>
> Cc: "users" <<a href="mailto:Users@ovirt.org">Users@ovirt.org</a>>, "Vojtech Szocs" <<a href="mailto:vszocs@redhat.com">vszocs@redhat.com</a>><br>
> Sent: Wednesday, November 5, 2014 12:37:21 AM<br>
> Subject: Re: Fwd: [ovirt-users] Integration of ovirt-engine GUI with the CLI<br>
><br>
> On 11/04/2014 01:54 PM, Nikita Kodkani wrote:<br>
> > Hi,<br>
> ><br>
> > To add further...<br>
> > I read it somewhere on google, that to execute the shell commands in the<br>
> > JavaScript we have to use node.js at the backend.<br>
> ><br>
> > We don't want to spend time on learning the technology in this time frame.<br>
> ><br>
> > -Does ovirt-engine provide API's for executing the shell commands?<br>
><br>
> its the other way around - the cli/shell commands are using the engine<br>
> python-sdk, which uses the engine REST API.<br>
><br>
> if your solution is html/javascript based, i think using ovirt.js (which<br>
> wraps calling to the engine rest api 'nicely', vs. you doing it yourself<br>
> from your code) is the way to go.<br>
<br>
Exactly, the main use case for oVirtJS is to allow working with Engine<br>
from within a JavaScript environment. HTML/JS web application is the<br>
primary use case, we also plan to support "server-side JS code running<br>
on Node.js" as another use case, so that people can potentially write<br>
custom server-side JS to work with Engine.<br>
<br>
><br>
> <a href="http://lists.ovirt.org/pipermail/users/2014-June/025198.html" target="_blank">http://lists.ovirt.org/pipermail/users/2014-June/025198.html</a><br>
> <a href="http://www.ovirt.org/Features/Design/Using_REST_API_In_Web_UI" target="_blank">http://www.ovirt.org/Features/Design/Using_REST_API_In_Web_UI</a><br>
> <a href="http://lists.ovirt.org/pipermail/devel/2014-August/008502.html" target="_blank">http://lists.ovirt.org/pipermail/devel/2014-August/008502.html</a><br>
> <a href="http://lists.ovirt.org/pipermail/devel/attachments/20140819/a35caa44/attachment-0001.pdf" target="_blank">http://lists.ovirt.org/pipermail/devel/attachments/20140819/a35caa44/attachment-0001.pdf</a><br>
><br>
><br>
> ><br>
> ><br>
> > Thanks,<br>
> > Nikita<br>
> ><br>
> > Nikita Kodkani<br>
> ><br>
> ><br>
> > On Tue, Nov 4, 2014 at 4:20 PM, Itamar Heim <<a href="mailto:iheim@redhat.com">iheim@redhat.com</a><br>
> > <mailto:<a href="mailto:iheim@redhat.com">iheim@redhat.com</a>>> wrote:<br>
> ><br>
> > On 11/04/2014 11:47 AM, Nikita Kodkani wrote:<br>
> ><br>
> > It is designed in javascript/HTML. We had initially designed some<br>
> > feature using CLI. But now we just want to execute command when<br>
> > we hit<br>
> > the button/tab.<br>
> ><br>
> ><br>
> > vojtech - sounds like ovirt.js could be the best fit here?<br>
> ><br>
> > -Nikita<br>
> ><br>
> > i<br>
> ><br>
> ><br>
> > On Tue, Nov 4, 2014 at 4:09 PM, Itamar Heim <<a href="mailto:iheim@redhat.com">iheim@redhat.com</a><br>
> > <mailto:<a href="mailto:iheim@redhat.com">iheim@redhat.com</a>><br>
> > <mailto:<a href="mailto:iheim@redhat.com">iheim@redhat.com</a> <mailto:<a href="mailto:iheim@redhat.com">iheim@redhat.com</a>>>> wrote:<br>
> ><br>
> > On 11/04/2014 06:30 AM, Nikita Kodkani wrote:<br>
> ><br>
> > Hi,<br>
> ><br>
> > I have the CLI designed for the RHEV-M. I have also<br>
> > designed<br>
> > some GUI in<br>
> > ovirt-engine.<br>
> > Now I am stuckup with the integration. Could you<br>
> > suggest how to<br>
> > connect<br>
> > the ovirt-engine GUI with the backend CLI commands?<br>
> ><br>
> ><br>
> > which language is your gui?<br>
> > why use the CLI instead of the python or java SDKs<br>
> > (or ruby or javascript ones)<br>
> ><br>
> ><br>
> ><br>
> ><br>
> ><br>
><br>
><br>
</blockquote></div>