-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reverb support #61
Comments
That would be awesome, I wonder if @yolcuiskender has played with Reverb at all? Know he's doing a bunch of cool stuff with Lando and various Laravel services... |
I haven't had the opportunity to use reverb yet, but I'm willing to give it a try in the next few days. Based on my initial understanding, I don't foresee encountering significant problems. However, if there are any specific aspects you'd like me to focus on or if you have any concerns, please feel free to let me know. Looking forward to contributing to this issue. |
Any news about this? We are trying to set it up by ouserlves, but so far no success.
Apparently reverb correctly starts to listen (looking at the logs) but we haven't found a way to make the app talk to the ws server. We always end up with failed connection:
Following some other guide we also have configured a custom nginx.conf adding this:
|
The solution I know lies in the nginx config but I'm only good enough to be
dangerous in that respect. I just haven't made the time to try things out
myself.
…On Thu, May 9, 2024, 4:30 AM maikezan ***@***.***> wrote:
Any news about this? We are trying to set it up by ouserlves, but so far
no success.
This is our current lando.yml:
name: test_app
recipe: laravel
config:
webroot: public
php: 8.2
xdebug: true
via: nginx
database: mysql:8.0
cache: redis
services:
node:
type: node:18
scanner: false
ports:
- 3009:3009
database:
portforward: 3307
cache:
portforward: 32293
appserver:
config:
server: .nginx/server.conf
queue:
type: php:8.2
via: cli
command: php artisan horizon
reverb:
type: php:8.2
via: cli
ssl: true
command: php artisan reverb:start --debug
overrides:
ports:
- 8080:8080
networks:
- network_default
networks:
network_default:
driver: bridge
tooling:
npm:
service: node
node:
service: node
Apparently reverb correctly starts to listen (looking at the logs) but we
haven't found a way to make the app talk to the ws server. We always end up
with failed connection:
WebSocket connection to 'wss://videomood.lndo.site/app/wkvtwtt7uvf8kmmkjjgv?protocol=7&client=js&version=8.4.0-rc2&flash=false' failed:
createWebSocket @ pusher-js.js?v=20883fe9:3268
—
Reply to this email directly, view it on GitHub
<#61 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAXJKNSVEYFC4AOTBQHM3YLZBM64FAVCNFSM6AAAAABGQVMHO2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMBSGI4TQNRZG4>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Yea there is something in the network part i'm missing. Amazingly i can succesfully connect to the websocket server now from outside the application (via POSTMAN) but not from within the app container, so there must be something up there. |
@maikezan are you using the correct hostname within the container environment for the wss server? For example, if you're trying to call the |
this is something i need to test again. I think that was one of our first attempts and it didn't work. But we've made so many tests that i honestly need to rerun again with this and see if it works. Thanks for the suggestion |
So far no luck with using "reverb" as hostname. this is our current lando.yml for reverb:
And .env file for reverb:
|
Hi @maikezan ! |
Hey @edouardgab , unfortunately i haven't resolved this. I'm currently using Laragon locally which works with some tweaks on the nginx configuration.
I had tested this change in the lando nginx conf before, but failed to make it work. Maybe it can help you somehow? |
Hi @maikezan , Thansk for your reply ! Since my message, I was actually able to figure this out :) It was actually pretty simple once the right settings were found ! .env:
I think everything you share was properly working, the issue was the necessity to properly listen to the events : I did set it up in Postman to make it easier. Url : First, connect to the websocket:
Then subscribe the the event
Hope this helps ! PS : I cannot look at the .lando.yml right now so I did by head. But it was fairly similar to what you did. Edit : One small tip: look at the console of Reverb in Docket Desktop. That really help understanding what is going on. |
@edouardgab thank you for sharing your solution. I'll be giving it a try as soon as possible. i was sure we were "there" with the right approach. |
This was a big help guys, thanks! I can't seem to get it to work using a secure socket in the browser, but it does work in Postman. I guess because Chrome is objecting to the security certificate or similar. But works over an insecure socket in both the browser and Postman. |
So I managed to get this working. SSL WebSockets between Laravel Echo and Laravel Reverb, through Lando. Laravel
I am using a custom NGINX config in my Landofile, and exposing the reverb port. Landofile
The most important part of the NGINX config (aside from the proxies) was to add Without that resolver, NGINX was not able to connect to the NGINX config
The Echo setup is just regular.
|
Hey @roberttolton ! |
Ohh that is slick! Could this get a PR for the masses? |
@maikezan Which values are you referring to? Do you mean @jameswagoner I can try although I don't know how to recipe-ify the |
Sorry i haven't specified actually :|
|
I guess those aren't strictly necessary since the destination URI ends up being the same as the input. |
Going to give it another try as soon as possible. Thanks meanwhile ! |
Would be nice for out of the box support for Reverb or a guide if it just needs some tweaking of the YML.
I have tried various things to get a connection going and always ends up with a connection refused error.
The text was updated successfully, but these errors were encountered: