Skip to content

Secure websockets on app engine (?) #265

Description

@michalczaplinski

The README for the appengine/websockets example says:

To use Secure WebSockets now, you can launch a VM on Google Compute Engine using a custom image where you have added SSL support for WebSockets.

It would be great if the README could elaborate on this, as most sites are served over HTTPS nowadays and thus also require the websockets connection to be secure. This is also my usecase!

In, fact any suggestion on how supporting SSL inside that docker image could be achieved, would be greatly appreciated!

Activity

  1. changed the title [-]Secure Websockets (?)[/-] [+]Secure websockets on app engine (?)[/+] on Nov 24, 2016
  2. jmdobry commented on Dec 6, 2016

    @jmdobry
    Member

    @JustinBeckwith Any thoughts?

  3. petrnetusil commented on Mar 4, 2017

    @petrnetusil

    Bump. Same question here. Need secure websockets on App Engine for our node.js implementation. So far, this seems to be the last issue preventing us from moving our Production env. to App Engine. Any updates?

  4. elithrar commented on May 27, 2017

    @elithrar

    If/while this is being worked on, can some of the reasons for no WSS support on App Engine flexible be shared?

    GCP's general approach to security has been great, and the advice to use a VM goes against why many use GAE to begin with (minimal ops!).

  5. jwickens commented on Jun 13, 2017

    @jwickens

    Same here, we opted out of using socket.io over the apparent widespread support for websockets so its a must. Unsecure apps even for development just seems unwise.

  6. danieljodeci commented on Jul 6, 2017

    @danieljodeci

    Same here, would appreciate an example on setting up secured websockets on a manage vm

  7. edmothershaw commented on Jul 10, 2017

    @edmothershaw

    Did anyone manage to solve this successfully? I have an implementation of a secure websocket server that appears to be running on Appengine but on connection to the websocket I receive the response

    failed: Error in connection establishment: net::ERR_INSECURE_RESPONSE 
    

    Edit: On further investigation, the error arises from the use of self-signed certificates.

  8. art-grig commented on Jan 1, 2018

    @art-grig

    @edmothershaw, please can you tell how have you achieved it?
    Does appengine flex support secure websockets now? Or is there some workaround?

  9. edmothershaw commented on Jan 4, 2018

    @edmothershaw

    The solution we eventually went with was to deploy the websocket server in Kubernetes.
    I'm unsure if it supports it now but my guess is that it does not and probably never will (appengine/websockets is no longer included in the sample docs). They suggest using compute engine in this example https://cloud.google.com/solutions/real-time-gaming-with-node-js-websocket

  10. art-grig commented on Jan 4, 2018

    @art-grig

    Thank you so much for response, yes it seems so and here is commit: 18210b3

    So compute engine is the way I go.

  11. Ajaxy commented on Jan 30, 2018

    @Ajaxy

    @art-grig Is there any example or documentation on how to run WebSockets service with Node.js on Compute Engine?

  12. art-grig commented on Jan 30, 2018

    @art-grig

    @Ajaxy there is nothing special about Compute Engine for configuring websockets with node js, I would suggest to make it over nginx, this could be helpfull:
    https://blag.felixhummel.de/junk/nginx_socketio_wss_test.html

  13. Ajaxy commented on Jan 30, 2018

    @Ajaxy

    @art-grig Thanks for the link. Well, I’m not sure, “Compute Engine” doesn’t sound like a proper place for a tiny WS service. I’m just using ML Engine for serving AI service, so I thought would be convinient to store all parts on GCloud. Now I’m thinking about using Heroku for WS service.

  14. WaldoJeffers commented on Mar 27, 2018

    @WaldoJeffers

    Hello everyone, are there any updates on this? 😄

  15. 21 remaining items

  16. Grifting commented on Nov 24, 2023

    @Grifting

    So is it still not possible to have WebSockets in 2023 on any container service from google? Cloud Run, App Engine without using Long Polling or Socket.io

  17. steren commented on Nov 27, 2023

    @steren
    Contributor

    Cloud Run has support for websockets: https://cloud.google.com/run/docs/triggering/websockets

  18. Grifting commented on Nov 27, 2023

    @Grifting

    Thank you very much, my mistake was I used WebSocket and not WebSocket Secure. The client refused to make a request. It works all fine now. Happy hacking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    🚨This issue needs some love.triage meI really want to be triaged.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions