title: Lucee 5.0 websocket outside localhost
body: <p>Hey everybody reading this,</p>
  
  <p>Lately I'm busy researching websockets and in particularly websockets in Lucee. I had some difficulties installing it through the admin menu (solution: update lucee to the latest version -_-) after that the extension was successfully installed. </p>
  
  <p>The second thing I tried was to implement the most simple example of websockets found here: <a href="https://github.com/isapir/lucee-websocket/wiki/Example---Echo" rel="nofollow noreferrer">https://github.com/isapir/lucee-websocket/wiki/Example---Echo</a>. He also made a video explaining his steps. I ran into some connection issue's and after some hours I got something working.</p>
  
  <p>First let me tell you what the configuration is: I'm working on a windows server 2012 R2 and here is Lucee successfully running. Some websites are configured in IIS and everything is working perfect. In case of the websockets I successfully ran a console test through IE on the server with localhost. I could send a message and receive it. I used the url: ws://localhost:8888/ws/echo (as in the example). </p>
  
  <p>Now the problem I'm having is that I want to do the same externally. Of course you cannot use localhost then so I tried every combination possible, but every time it says something like "ERR_CONNECTION_TIMEOUT" or "ERR_CONNECTION_REFUSED" etc.   </p>
  
  <p>What I think is that the websocket extension is working like it should, but the connection is refused by IIS or Tomcat. Therefore I also installed websocket support in IIS, enabled it, but still nothing. </p>
  
  <p>Can somebody point me in the right direction why this is happening? Is it something with a port, or a setting in tomcat. I'm  not really good at this stuff, I'm happier just programming applications. Hopefully somebody can help.</p>
  
  <p>You also have a test application here: <a href="https://www.websocket.org/echo.html" rel="nofollow noreferrer">https://www.websocket.org/echo.html</a> but this is not working for my url. </p>
  
  <p>PS: I also need to use a VPN to connect to the server. Is this something to consider? </p>
  
  <p>Thanks,</p>
  
  <p>Roland</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>Let me give you an update. First let me state that, like I said, we already have websites working on an open domain through IIS. These are working excellent externally. Now when I try to connect to the websocket through an open domain with the port 80, I get a 404 error. When I try it with port 8888 then It gives the following response:</p>
  
  <blockquote>
    <p>WebSocket Error: Network Error 12029, A connection with the server could not be established</p>
  </blockquote>
  
  <p>If I get the 404 this is the response:
  <a href="https://i.stack.imgur.com/1zv3m.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/1zv3m.png" alt="enter image description here"></a></p>
  
  <p>But I'm probably not the only one who wants to have websockets working outside localhost. For instance how can I get this working on port 80? That would be better instead of opening other ports. </p>
  
  <p>Hopefully somebody can help me, thanks!</p>