Laravel Reverb (WebSocket) on VPS Over HTTPS | Complete Guide

Поділитися
Вставка
  • Опубліковано 27 лис 2024

КОМЕНТАРІ • 30

  • @hennaraufi3368
    @hennaraufi3368 3 місяці тому +1

    I like that thanks 😮😮😮

    • @eraufi
      @eraufi  3 місяці тому

      thanks

  • @uniqueboxoffice
    @uniqueboxoffice 3 місяці тому

    Laravel reverb work fine in web using Laravel Echo. But How can we use Laravel Reverb Socket Notification in Mobile Application Android/iOS?

    • @eraufi
      @eraufi  3 місяці тому

      i am sorry but i don't have any experience with mobile applications

  • @WildNatureNP
    @WildNatureNP 14 днів тому

    i am getting the error
    WebSocket is closed before the connection is established.
    when deployed on server.

    • @eraufi
      @eraufi  14 днів тому

      try adding a timeout for 300 or 500 milliseconds in the client side if the problem is not solved please watch
      41:10 Solving Common Problems

    • @WildNatureNP
      @WildNatureNP 14 днів тому

      @@eraufi thanks for the reply
      i see our private hosting have more than 2 websites running already on it. will it change or affect anything?

    • @eraufi
      @eraufi  14 днів тому

      @@WildNatureNP will it's hard to say. because I don't have much information about your hosting or projects. but normally it won't change or affect anything else

    • @WildNatureNP
      @WildNatureNP 14 днів тому

      @@eraufi hmm. interesting.
      the thing is this is running perfectly fine in local, but when i put it on server, always getting this same error.
      websocket is closed before connection is established

    • @WildNatureNP
      @WildNatureNP 14 днів тому

      i am not able to get the not found when put on domainname:port

  • @Demen77
    @Demen77 3 місяці тому

    please how did you host it

    • @eraufi
      @eraufi  3 місяці тому

      brother all the steps are in the video

  • @lksccb
    @lksccb 2 місяці тому +1

    Sh!t. for me not works. CloudPanel. Installed certificates, and wss problem like on video. but not working with solution.

    • @eraufi
      @eraufi  2 місяці тому +1

      sorry to hear that. but have you watched and applied 41:10 Solving Common Problems

    • @lksccb
      @lksccb 2 місяці тому

      @@eraufi Yes, I watched it and was very happy to see that you had the same problem as me. However, when I replicated the solution just like you, I was not successful.
      When I am using HTTP, everything works. Reverb works over WS.
      But when I activate the site's SSL, Reverb stops working over HTTP and forces it to use WSS. And then I did the procedure for the certificates and SSL correctly, just like in the video (but with my domain and files). And now the site is in HTTPS and Reverb is also in WSS. However, it is not connecting. Same problem as in your video.

    • @eraufi
      @eraufi  2 місяці тому +1

      @@lksccb thanks for the replay.
      I faced this problem before and I had a tough time finding the solution. after finding the solution i made a video about it so for others it should be easy to solve it.
      could you please share the solution in here when ever you solve it?

    • @lksccb
      @lksccb 2 місяці тому

      @@eraufi Yes, I can come back. I also had this problem in production once. Before Reverb, back in the Pusher era. And I remember that I had a hard time solving it. Honestly, I'm almost giving up on this. It seems to be a chronic problem with Laravel when it comes to configuring Websockets with SSL. Unfortunately, I don't remember how I solved it, but if I manage to solve my problem, I'll come back here to explain.
      As I said, if the project is running on SSL, the browser forces the use of WSS even if you want to use WS.

    • @eraufi
      @eraufi  2 місяці тому

      @@lksccb thanks you very much.
      one time i remembered in one of my laravel 10 projects i faced this problem. after searching a lot i solved it just by opening websocket link and port in the browser.
      for example like this
      www.myproject.come:8080
      it registered the SSL in the browser and everything worked fine

  • @KesleyWp
    @KesleyWp 11 днів тому

    Please, do it on Nginx! The connection isn't working!
    And Nginx uses ports 8080 and 443

    • @eraufi
      @eraufi  11 днів тому +1

      i am sorry but i don't have a vps. the one the i used for this video was provided by one of my viewers.