I have been tried to configure with Apache web server, but I got no luck.
Would you please kindly provide doc for how to configure with Apache web server?
I had the same issue on Apache, could not get it to connect.
After 2 hours on the internet, I tried every configuration possible.
Finally got it to work:
If you are using let's encrypt and Plesk with Apache you need to get the correct certificates. Plesk puts them in a different place.
/*
* Path to local certificate file on filesystem. It must be a PEM encoded file which
* contains your certificate and private key. It can optionally contain the
* certificate chain of issuers. The private key also may be contained
* in a separate file specified by local_pk.
*/
'local_cert' => env('LARAVEL_WEBSOCKETS_SSL_LOCAL_CERT', '/usr/local/psa/var/modules/letsencrypt/etc/live/example.com/fullchain.pem'),
/*
* Path to local private key file on filesystem in case of separate files for
* certificate (local_cert) and private key.
*/
'local_pk' => env('LARAVEL_WEBSOCKETS_SSL_LOCAL_PK', '/usr/local/psa/var/modules/letsencrypt/etc/live/example.com/privkey.pem'),
It's also really important to make sure your server is not blocking port 6001.
Mine is hosted on IONOS and they have their own dashboard which you need to allow the port through for it to work.
Chrome Specific
In websockets.php you need this in the ssl array for it to work
'verify_peer' => false,
Not sure why but there is some sort of cert bug at the moment with the package which makes it not connect.
@Kyon147 Thanks man. This is very important to Plesk servers. 2 hours searching for this answer!
i did but it didn't error: app.js:39150 WebSocket connection to 'wss://sub.xsite.com.tr/app/abc?protocol=7&client=js&version=4.4.0&flash=false' failed: Error during WebSocket handshake: Unexpected response code: 404
I haven't solved for 4 days :(
Most helpful comment
I had the same issue on Apache, could not get it to connect.
After 2 hours on the internet, I tried every configuration possible.
Finally got it to work:
If you are using let's encrypt and Plesk with Apache you need to get the correct certificates. Plesk puts them in a different place.
It's also really important to make sure your server is not blocking port 6001.
Mine is hosted on IONOS and they have their own dashboard which you need to allow the port through for it to work.
Chrome Specific
In websockets.php you need this in the ssl array for it to work
'verify_peer' => false,Not sure why but there is some sort of cert bug at the moment with the package which makes it not connect.