Giter Site home page Giter Site logo

Comments (3)

ekzhang avatar ekzhang commented on May 8, 2024 2

Hi @orhun, thanks for looking into this. TLS configuration isn't in the documentation because the server doesn't have TLS support. You can configure a reverse proxy like Nginx for HTTPS and WebSocket. The public deployment is on DigitalOcean App Platform, which handles this automatically.

I think it is possible to add TLS support, as both warp and tokio-tungstenite can do this via rustls, but I'm not certain of the advantages of this over just using a reverse proxy.

from rustpad.

ekzhang avatar ekzhang commented on May 8, 2024 1

Great, thanks for sharing your configuration!

from rustpad.

orhun avatar orhun commented on May 8, 2024

Ok I managed to get it done by using Nginx reverse proxy:

server {
  listen 443 ssl;

  # setup SSL certificates
  # ssl_certificate ...
  # ...

  location / {
   proxy_http_version 1.1;
   proxy_set_header Upgrade $http_upgrade;
   proxy_set_header Connection "upgrade";
   proxy_pass http://localhost:3030/;
  }
}

from rustpad.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.