Re: [one-users] Getting VNC token from Sunstone REST API

2015-02-10 Thread Daniel Molina
On 9 February 2015 at 14:16, Daniel Dehennin daniel.dehen...@baby-gnu.org
wrote:

 Daniel Dehennin daniel.dehen...@baby-gnu.org writes:

  We use jenkins to automate the installation of VM from ISO images[1] and
 we
  use something similar to jenkins.debian.net[2] which use vncdo[3].

 [...]

  We would like to get the token from Sunstone REST API:
 
  https://nebula.example.net/vm/VMID/startvnc
 
  but we don't see how to manage the authentication?

 Hello,

 It looks like I need the csrftoken but I don't know how to retrieve it.

 Any hint?


The csrftoken is stored in the user session on the server and is injected
in the index.html

Cheers


 Regards.
 --
 Daniel Dehennin
 Récupérer ma clef GPG: gpg --recv-keys 0xCC1E9E5B7A6FE2DF
 Fingerprint: 3E69 014E 5C23 50E8 9ED6  2AAD CC1E 9E5B 7A6F E2DF

 ___
 Users mailing list
 Users@lists.opennebula.org
 http://lists.opennebula.org/listinfo.cgi/users-opennebula.org




-- 
--
Daniel Molina
Project Engineer
OpenNebula - Flexible Enterprise Cloud Made Simple
www.OpenNebula.org | dmol...@opennebula.org | @OpenNebula
___
Users mailing list
Users@lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org


Re: [one-users] Getting VNC token from Sunstone REST API

2015-02-09 Thread Daniel Dehennin
Daniel Dehennin daniel.dehen...@baby-gnu.org writes:

 We use jenkins to automate the installation of VM from ISO images[1] and we
 use something similar to jenkins.debian.net[2] which use vncdo[3].

[...]

 We would like to get the token from Sunstone REST API:

 https://nebula.example.net/vm/VMID/startvnc

 but we don't see how to manage the authentication?

Hello,

It looks like I need the csrftoken but I don't know how to retrieve it.

Any hint?

Regards.
-- 
Daniel Dehennin
Récupérer ma clef GPG: gpg --recv-keys 0xCC1E9E5B7A6FE2DF
Fingerprint: 3E69 014E 5C23 50E8 9ED6  2AAD CC1E 9E5B 7A6F E2DF


signature.asc
Description: PGP signature
___
Users mailing list
Users@lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org


[one-users] Getting VNC token from Sunstone REST API

2015-02-05 Thread Daniel Dehennin
Hello,

We use jenkins to automate the installation of VM from ISO images[1] and we
use something similar to jenkins.debian.net[2] which use vncdo[3].

We retrieve the host where the VM is running and the VNC port from the
XML RPC API and open a direct connection to the qemu VNC server.

With our first “developer only” cluster, we did not have any issue since
the cluster nodes are on the same network than our workstations.

With our “soon in production” cluster, the nodes are not on a reachable
network and we need to connect through the WebSocket proxy.

The VNC token is not available through the XML RPC API[4], which could
be seen as normal because it's managed by Sunstone and shared with
websocketproxy on a possibly different machine than the OpenNebula
daemon.

We would like to get the token from Sunstone REST API:

https://nebula.example.net/vm/VMID/startvnc

but we don't see how to manage the authentication?

Does someone manage to retrieve the token pragmatically?

Regards.

Footnotes: 
[1]  to test the installation of our french distribution for schools

[2]  https://jenkins.debian.net

[3]  
http://anonscm.debian.org/cgit/qa/jenkins.debian.net.git/tree/bin/g-i-installation.sh#n402

[4]  http://dev.opennebula.org/issues/2655

-- 
Daniel Dehennin
Récupérer ma clef GPG: gpg --recv-keys 0xCC1E9E5B7A6FE2DF
Fingerprint: 3E69 014E 5C23 50E8 9ED6  2AAD CC1E 9E5B 7A6F E2DF


signature.asc
Description: PGP signature
___
Users mailing list
Users@lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org