Ganeti Web Manager:
completed by: Piotr Banaszkiewicz
mentors: Peter Krenesky, Lance Albertson
Please make sure to submit your patch for this task and to take required notes for it in the OSUOSL issue tracker at http://code.osuosl.org/issues/2301. Required notes would include letting the community know you are working on the issue with a note in the tracker, any notes on progress or difficulties implementing, etc.
For help with this task, contact kreneskyp or ramereth in #ganeti-webmgr on Freenode.
Description
Since we have a multi-user environment we would like a single daemon that can manage our websocket-vnc-portforwarding.
requirements:
- must have a control channel
- REST, Preferably a server in the standardlib (yes i know httpserver is horribly inefficient, but this is the control channel only)
- allow localhost only
- should allow a predefined port pool for local ports. e.g. use ports 1000 through 2000:
- Unless a specific port is requested, choose the first port available.
- ports should be returned to the pool when the websocket closes
- generate a random password that can be used to connect to the requested port.
- individual websockets should be cleaned up:
- when the VNC client disconnects
- or no VNC client connects after a short timeout (30 secs)
- this should all be done, ideally, without altering the NoVNC code. we'd like to maintain compatibility.
1 # sample use of client
2 proxy_host, proxy_port, password = client.forward_port(dest='ganeti-node.osuosl.org', port=12345)