[英]How can I make Supervisor run on a different port than the default 6001?
[英]Supervisor wont run file located in /usr/bin but I can run it if I cd to it and run it manually
我無法讓主管在我的 Ubuntu 16.04 AWS EC2 實例上運行 laravel echo 服務器,但它在我的 Homestead Ubuntu 16.04 VM 上運行良好。 我得到的錯誤是找不到命令'/usr/bin/laravel-echo-server。 如果我直接 cd 到/usr/bin
並運行laravel-echo-server start
它以開發模式啟動就好了
我正在運行節點 V8.9.1
這是我的配置文件中的內容
[program:laravel-worker]
process_name=%(program_name)s_%(process_num)04d
command=/usr/bin/laravel-echo-server start --dir=/var/www/html/bcbAPI
autostart=true
autorestart=true
user=root
redirect_stderr=true
stdout_logfile=/var/www/html/bcbAPI/storage/logs/echoserver.log
stderr_logfile=/var/www/html/bcbAPI/storage/logs/echoserver-error.log
laravel-echo-server.json
{
"authHost": "http://myip.com/b3",
"authEndpoint": "/broadcasting/auth",
"clients": [
{
"appId": "aa41c60c83ffa7f7",
"key": "70e24d91c54f9f30d1fbdb2ed3f2cce8"
}
],
"database": "redis",
"databaseConfig": {
"redis": {
"port": "6379",
"host": "localhost"
},
"sqlite": {
"databasePath": "/database/laravel-echo-server.sqlite"
}
},
"devMode": true,
"host": null,
"port": "6001",
"protocol": "http",
"socketio": {
"wsEngine": "uws"
},
"sslCertPath": "",
"sslKeyPath": "",
"sslCertChainPath": "",
"sslPassphrase": "",
"apiOriginAllow": {
"allowCors": true,
"allowOrigin": "myiphere/b2",
"allowMethods": "GET,POST,PUT",
"allowHeaders": "Origin, Content-Type, X-Auth-Token, X-Requested-With, Accept, Authorization, X-CSRF-TOKEN, X-Socket-Id"
}
}
一切之前,請檢查和的NodeJS laravel回聲服務器的絕對路徑:
which node
which laravel-echo-server
將 nodejs 和 laravel-echo-server PATH 添加到您的命令中后:
command=/bin/node /bin/laravel-echo-server start --dir=YOUR_ABSOLUTE_PROJECT_PATH
問題解決了!
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.