Comments (2)
You should use different PIDs for different websocket apps.
On Sep 16, 2016 15:35, "ryzhak" [email protected] wrote:
Hello.
Is it possible to run 2 websocket servers on 1 VDS?
I have 2 web applications on 1 VDS. Both of them use your yii2 websocket
extension.To start the 1st websocket server I run:
cd /var/www/app1
./yii websocket/start notificationServer1But when I run the 2nd websocket server:
cd /var/www/app2
./yii websocket/start notificationServer2then I get "already started" in the console output. I want the 2nd server
working as well.How can I make it work?
config1:
'websocket' => [
'class' => 'morozovsk\yii2websocket\Connection',
'servers' => [
'notificationServer1' => [
'class' => 'app\modules\v1\modules\notification\components
WebsocketDaemonHandler',
'pid' => '/tmp/websocket_chat.pid',
'websocket' => 'tcp://127.0.0.1:8004',
'localsocket' => 'tcp://127.0.0.1:8010'
]
],
],config2:
'websocket' => [
'class' => 'morozovsk\yii2websocket\Connection',
'servers' => [
'notificationServer1' => [
'class' => 'app\modules\v1\modules\notification\components
WebsocketDaemonHandler',
'pid' => '/tmp/websocket_chat.pid',
'websocket' => 'tcp://127.0.0.1:8014',
'localsocket' => 'tcp://127.0.0.1:8024'
]
],
],Hope you got what I mean. Thanks in advance.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#22, or mute the thread
https://github.com/notifications/unsubscribe-auth/ADHQEh1d_uhsFZtfoEjoM9OJ7OItoD0Gks5qqo0LgaJpZM4J-5GG
.
from websocket.
Thank you. I changed 'pid' in the config files and it worked.
from websocket.
Related Issues (20)
- Как подружить с pg_notify HOT 4
- GenericEvent считывает не весь буфер HOT 2
- список онлайн юзеров HOT 8
- Отправка изображения через вебсокет
- Работа в Safari HOT 1
- wss timeot HOT 17
- stream_select(): supplied argument is not a valid stream resource HOT 7
- Не закрывает соединение при окончании на сайте HOT 4
- Как сделать многопоточность? HOT 6
- request response order HOT 1
- Можно ли создавать комнаты? HOT 12
- PHP Client HOT 3
- Один конект по сокету на несколько вкладок HOT 2
- Потраченное время на разработку. HOT 4
- Не сбрасываются коннекты HOT 12
- "Залипает" при слишком длинном handshake-сообщение (режим event) HOT 4
- websocket lunch on remote host HOT 1
- Ошибка при остановке HOT 2
- Каково потребление памяти и cpu при нагрузке в 100 000 соединений? HOT 4
- Почему бросили? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from websocket.