When trying to run the deamon I was constantly getting the following error;
websockets: ERROR (spawn error)
After some debugging and enabling loggin in the websockers.conf file I found that the problem was:
2019-01-08 21:15:43,932 INFO spawned: 'websockets' with pid 13139
2019-01-08 21:15:43,972 INFO exited: websockets (exit status 1; not expected)
Could not open input file: /home/laravel-echo/laravel-websockets/artisan
Now I'm not really sure how to fix this. I went checking and there is not laravel-echo folder in my home directory.
But I deploy with forge, am I missing something here?
Also informative:
$ sudo supervisorctl status
websockets FATAL Exited too quickly (process log may have details)
I managed to fix it:
I wasn't aware that in the command line you have to change two things, the user and the folder where you site is located.
This is the docu;
[program:websockets]
command=/usr/bin/php /home/laravel-echo/laravel-websockets/artisan websockets:serve
numprocs=1
autostart=true
autorestart=true
user=laravel-echo
I've changed:
command=/usr/bin/php /home/laravel-echo/laravel-websockets/artisan websockets:serve
To
command=/usr/bin/php /home/{my user}/{my site}/artisan websockets:serve
_Beware, this is deployed via forge, custom deployments may differ!_
Most helpful comment
I managed to fix it:
I wasn't aware that in the command line you have to change two things, the user and the folder where you site is located.
This is the docu;
I've changed:
command=/usr/bin/php /home/laravel-echo/laravel-websockets/artisan websockets:serveTo
command=/usr/bin/php /home/{my user}/{my site}/artisan websockets:serve_Beware, this is deployed via forge, custom deployments may differ!_