Hello, I'm new to Guacamole and as the title states, I am trying to embed an
RDP connection inside of a custom website. 

First, I wonder if there is a tutorial or docs somewhere that clearly
outline the process? I couldn't find much info anywhere that clearly outline
the steps that are required and instead, I find myself trying to reverse
engineer the front end AngularJS code for the Guacamole Web Server UI that
is able to provide such an RDP connection inside of the HTML.

Next, the area where I am currently stuck is creating the Guacamole client
using a WebSocket tunnel. For context, the Guacamole Web Server and website
that I want to embed the RDP connection are on completely different domains
/ urls, so when I pass the `tunnelUrl` parameter, I am giving full path. 

Here is my code: 

            let tunnel;
            if (window.WebSocket) {
                const authToken = localStorage.getItem('authToken');
                const connectUrl =
`ws://localhost:8080/guacamole/websocket-tunnel?token=${encodeURIComponent(authToken)}&GUAC_DATA_SOURCE=mysql&GUAC_ID=5&GUAC_TYPE=c&GUAC_WIDTH=1007&GUAC_HEIGHT=981&GUAC_DPI=96&GUAC_TIMEZONE=America%2FVancouver&GUAC_AUDIO=audio%2FL8&GUAC_AUDIO=audio%2FL16&GUAC_IMAGE=image%2Fjpeg&GUAC_IMAGE=image%2Fpng&GUAC_IMAGE=image%2Fwebp`
                tunnel = new Guacamole.ChainedTunnel(
                    new Guacamole.WebSocketTunnel(connectUrl),
                )
            }
            const client = new Guacamole.Client(tunnel);


The result is a request which does not succeed in the same way that it does
for the Guac Web Server UI when performing RDP connection. There is an extra
`?undefined` at the end as you can see here:

Request URL:
ws://localhost:8080/guacamole/websocket-tunnel?token=0B1AB7A2B98659851D3681F5F63BA328D34A4D802295656F148DB232B395D0E8&GUAC_DATA_SOURCE=mysql&GUAC_ID=5&GUAC_TYPE=c&GUAC_WIDTH=1007&GUAC_HEIGHT=981?undefined

I do not get a status code of `101` like I do in the Guac Server UI. 


Any help appreciated.



--
Sent from: 
http://apache-guacamole-general-user-mailing-list.2363388.n4.nabble.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@guacamole.apache.org
For additional commands, e-mail: user-h...@guacamole.apache.org

Reply via email to