Closed ncamacho97 closed 2 years ago
@JohnXLivingston
What was your previous Peertube version? When upgrading to 4.2.0 (johnxlivingston/peertubelivechat:production-bullseye is in 4.2.0) there is a NodeJS version change, and plugins should be uninstalled/reinstalled to compile some dependencies again. See https://github.com/Chocobozzz/PeerTube/blob/936ce6e5635f3a52acbc799e1fcba9a948a7e390/CHANGELOG.md?plain=1#L24 . There is no risk to do so, settings are not deleted.
If this does not work, please copy/paste the content of the diagnostic page. I cannot access it, only instance's admin can.
Okay sir I'll check but I'm sure I'm on 4.2.0
I didn't have a previous version I installed production- bullseye so I'm unaware of what that version is. I'm assuming it's the 4.2.0
mdc773 is me too my other account
@JohnXLivingston `Diagnostic Starting tests: OK Browser: OK Backend connection: OK Webchat activated on videos: OK Chat will open automatically Displaying «open in new window» button Chat can be enabled on live videos. Chat is enabled for all lives. Webchat type: OK Using builtin Prosody Builtin Prosody and ConverseJS: KO The working dir is: /data/plugins/data/peertube-plugin-livechat/prosody Prosody will run on port '52800' Prosody will use http://localhost:9000/plugins/livechat/5.7.0/router/api/ as base uri from api calls Prosody modules path will be '/data/plugins/node_modules/peertube-plugin-livechat/dist/server/prosody-modules' Prosody rooms will be grouped by 'video'. By default, room content will be archived. Room content will be saved for '1w' The prosody configuration file (/data/plugins/data/peertube-plugin-livechat/prosody/prosody.cfg.lua) exists Prosody configuration file content is correct. Pid file /data/plugins/data/peertube-plugin-livechat/prosody/prosody.pid not found Additional debugging information Current prosody configuration daemonize = false; allow_registration = false; admins = { }; pidfile = "/data/plugins/data/peertube-plugin-livechat/prosody/prosody.pid"; plugin_paths = { "/data/plugins/node_modules/peertube-plugin-livechat/dist/server/prosody-modules"; }; data_path = "/data/plugins/data/peertube-plugin-livechat/prosody/data"; default_storage = "internal"; storage = "internal"; modules_enabled = { "roster"; "saslauth"; "carbons"; "version"; "uptime"; "ping"; "bosh"; "posix"; }; modules_disabled = { "s2s"; }; cross_domain_bosh = false; consider_bosh_secure = true; cross_domain_websocket = false; consider_websocket_secure = false; c2s_require_encryption = false; interfaces = { "127.0.0.1"; "::1"; }; c2s_ports = { "9000"; }; c2s_interfaces = { "127.0.0.1"; "::1"; }; s2s_ports = { }; s2s_interfaces = { "127.0.0.1"; "::1"; }; http_ports = { "52800"; }; http_interfaces = { "127.0.0.1"; "::1"; }; https_ports = { }; https_interfaces = { "127.0.0.1"; "::1"; }; log = { info = "/data/plugins/data/peertube-plugin-livechat/prosody/prosody.log"; error = "/data/plugins/data/peertube-plugin-livechat/prosody/prosody.err";
};
VirtualHost "syop.xyz" authentication = "http"; modules_enabled = { "ping"; "auth_http"; "http"; "bosh"; "vcard_peertubelivechat"; }; http_auth_url = "http://localhost:9000/plugins/livechat/5.7.0/router/api/user"; trusted_proxies = { "127.0.0.1"; "::1"; }; allow_anonymous_s2s = false; http_host = "syop.xyz"; http_external_url = "http://syop.xyz"; peertubelivechat_vcard_peertube_url = "http://localhost:9000";
VirtualHost "anon.syop.xyz" authentication = "anonymous"; modules_enabled = { "ping"; "http"; "bosh"; "random_vcard_peertubelivechat"; }; trusted_proxies = { "127.0.0.1"; "::1"; }; allow_anonymous_s2s = false; http_host = "syop.xyz"; http_external_url = "http://syop.xyz"; peertubelivechat_random_vcard_avatars_path = "/data/plugins/node_modules/peertube-plugin-livechat/dist/server/avatars";
Component "room.syop.xyz" "muc" muc_room_locking = false; muc_tombstones = false; muc_room_default_language = "en"; muc_room_default_public = false; muc_room_default_persistent = true; muc_room_default_members_only = false; muc_room_default_moderated = false; muc_room_default_public_jids = false; muc_room_default_change_subject = false; muc_room_default_history_length = 20; restrict_room_creation = false; http_host = "syop.xyz"; http_external_url = "http://syop.xyz"; modules_enabled = { "muc_http_defaults"; "muc_mam"; "muc_moderation"; "http_peertubelivechat_list_rooms"; "http_peertubelivechat_test"; }; muc_create_api_url = { "http://localhost:9000/plugins/livechat/5.7.0/router/api/room?apikey=***APIKey***&jid={room.jid|jid_node}"; }; muc_log_by_default = true; muc_log_presences = true; log_all_rooms = false; muc_log_expires_after = "1w"; muc_log_cleanup_interval = 14400; peertubelivechat_list_rooms_apikey = "APIKey"; peertubelivechat_test_apikey = "APIKey"; peertubelivechat_test_peertube_api_url = "http://localhost:9000/plugins/livechat/5.7.0/router/api/test?apikey=***APIKey***";
Prosody version Prosody 0.11.9
Data directory: /data/plugins/data/peertube-plugin-livechat/prosody/data Config directory: /data/plugins/data/peertube-plugin-livechat/prosody Source directory: /usr/lib/prosody Plugin directories: /data/plugins/node_modules/peertube-plugin-livechat/dist/server/prosody-modules /usr/lib/prosody/modules/
Lua version: Lua 5.2
Lua module search paths: /usr/lib/prosody/?.lua /usr/local/share/lua/5.2/?.lua /usr/local/share/lua/5.2/?/init.lua /usr/local/lib/lua/5.2/?.lua /usr/local/lib/lua/5.2/?/init.lua /usr/share/lua/5.2/?.lua /usr/share/lua/5.2/?/init.lua
Lua C module search paths: /usr/lib/prosody/?.so /usr/local/lib/lua/5.2/?.so /usr/lib/x86_64-linux-gnu/lua/5.2/?.so /usr/lib/lua/5.2/?.so /usr/local/lib/lua/5.2/loadall.so
LuaRocks: Not installed
Backend: select
lfs: LuaFileSystem 1.8.0 libevent: 2.1.12-stable luaevent: 0.4.6 lxp: LuaExpat 1.3.0 socket: LuaSocket 3.0-rc1 ssl: 1.0 `
Have you tried uninstalling and reinstalling the plugin?
If yes, can you try to save the plugin settings, and check if it works?
If not, can you check in /data/plugins/data/peertube-plugin-livechat/prosody/data
, there should be log files. Can you see any error?
warn[6/16/2022, 10:53:25 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:53:26 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:53:26 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:53:27 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:53:28 AM] Prosody status: Prosody is not running error[6/16/2022, 10:53:28 AM] It seems that the Prosody process is not up warn[6/16/2022, 10:58:50 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:58:50 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:58:51 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:58:52 AM] Prosody status: Prosody is not running warn[6/16/2022, 10:58:52 AM] Prosody status: Prosody is not running error[6/16/2022, 10:58:52 AM] It seems that the Prosody process is not up error[6/16/2022, 11:08:09 AM] Error in controller. { "err": "RequestError: connect ECONNREFUSED 127.0.0.1:52800\n at ClientRequest.<anonymous> (/data/plugins/node_modules/got/dist/source/core/index.js:970:111)\n at Object.onceWrapper (node:events:642:26)\n at ClientRequest.emit (node:events:539:35)\n at ClientRequest.emit (node:domain:475:12)\n at ClientRequest.origin.emit (/data/plugins/node_modules/@szmarczak/http-timer/dist/source/index.js:43:20)\n at Socket.socketErrorListener (node:_http_client:454:9)\n at Socket.emit (node:events:527:28)\n at Socket.emit (node:domain:475:12)\n at emitErrorNT (node:internal/streams/destroy:157:8)\n at emitErrorCloseNT (node:internal/streams/destroy:122:3)\n at processTicksAndRejections (node:internal/process/task_queues:83:21)\n at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1187:16)" } warn[6/16/2022, 11:08:22 AM] Prosody status: Prosody is not running warn[6/16/2022, 11:08:23 AM] Prosody status: Prosody is not running warn[6/16/2022, 11:08:23 AM] Prosody status: Prosody is not running warn[6/16/2022, 11:08:24 AM] Prosody status: Prosody is not running warn[6/16/2022, 11:08:24 AM] Prosody status: Prosody is not running error[6/16/2022, 11:08:24 AM] It seems that the Prosody process is not up
Did you do the other steps I mentionned?
Which files is this?
Is there a file /data/plugins/data/peertube-plugin-livechat/prosody/prosody.err ?
i can but i'm on docker so i wound have to connect to what? container
says something about failing to open ports
That's the first time is see this error. I don't really know how Docker works, and I have no server to test the image myself. Could it be because you have no IPv6 on your server?
I'm forsure going to stay on docker. Is there any chance you can try a debug this with your own docker setup..... its Farley easy to spin docker instance????
Please answer to my questions. Have you IPv6 on your server?
I have no way to test docker for now.
no i don't but i doing so now smh. look here >> https://docs.docker.com/config/daemon/ipv6/ says that "Note: IPv6 networking is only supported on Docker daemons running on Linux hosts."
And what's your host OS?
Ubuntu 22.04 on docker ofc
hey what about this gentlemen Here >> https://bavatuesdays.com/upgrading-peertube-and-running-the-livechat-plugin/ he's running docker as well i think with a revers proxy
i take that back the gentlemen at Reclaim Cloud says that ever since 4.2.0 the live chat isn't working
hey what about this gentlemen Here >> https://bavatuesdays.com/upgrading-peertube-and-running-the-livechat-plugin/ he's running docker as well i think with a revers proxy
Thats exactly the recommended way to do.
i take that back the gentlemen at Reclaim Cloud says that ever since 4.2.0 the live chat isn't working
Where?
I just read again the logs you posted yesterday. The way you pasted your logs make them very difficult to read. Next time, please use «triple back quotes» around your logs (3 times the character ` , the return to a new line, paste your logs, then again 3 backquotes to close). The IPv6 stuff seem to be old logs, from June 15th, not June 16th. It should not be related to the current problem.
In order to help me better understand your setup, please respond to each of these questions:
/data/plugins/data/peertube-plugin-livechat/prosody/prosody.err
, then save the plugin settings. This will try to restart the Prosody server. Then, copy the new content of this log file.9090 was an accident my fault, here is my plugin page
prosdy.err here
Jun 17 14:00:03 portmanager error Failed to open server port 52800 on ::1, Cannot assign requested address Jun 17 14:00:03 modulemanager error Error initializing module 'c2s' on 'syop.xyz': /usr/lib/prosody/core/portmanager.lua:108: attempt to index field '?' (a nil value) stack traceback: /usr/lib/prosody/core/portmanager.lua:108: in function 'activate' /usr/lib/prosody/core/portmanager.lua:168: in function 'register_service' /usr/lib/prosody/core/portmanager.lua:227: in function '?' /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75> (...tail calls...) /usr/lib/prosody/core/moduleapi.lua:310: in function 'add_item' /usr/lib/prosody/core/moduleapi.lua:357: in function 'provides' /usr/lib/prosody/modules/mod_c2s.lua:365: in main chunk [C]: in function 'xpcall' /usr/lib/prosody/core/modulemanager.lua:183: in function 'do_load_module' /usr/lib/prosody/core/modulemanager.lua:261: in function 'load' /usr/lib/prosody/core/modulemanager.lua:83: in function '?' /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75> (...tail calls...) /usr/lib/prosody/core/hostmanager.lua:108: in function 'activate' /usr/lib/prosody/core/hostmanager.lua:58: in function '?' /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75> (...tail calls...) /usr/lib/prosody/util/startup.lua:399: in function 'prepare_to_start' /usr/lib/prosody/util/startup.lua:635: in function 'f' /usr/lib/prosody/util/async.lua:139: in function 'func' /usr/lib/prosody/util/async.lua:127: in function </usr/lib/prosody/util/async.lua:125> Jun 17 14:00:03 mod_posix error Danger, Will Robinson! Prosody doesn't need to be run as root, so don't do it! Jun 17 14:00:03 mod_posix error For more information on running Prosody as root, see https://prosody.im/doc/root Jun 17 14:00:03 modulemanager error Error initializing module 'c2s' on 'anon.syop.xyz': /usr/lib/prosody/core/portmanager.lua:108: attempt to index field '?' (a nil value) stack traceback: /usr/lib/prosody/core/portmanager.lua:108: in function 'activate' /usr/lib/prosody/core/portmanager.lua:168: in function 'register_service' /usr/lib/prosody/core/portmanager.lua:227: in function '?' /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75> (...tail calls...) /usr/lib/prosody/core/moduleapi.lua:310: in function 'add_item' /usr/lib/prosody/core/moduleapi.lua:357: in function 'provides' /usr/lib/prosody/modules/mod_c2s.lua:365: in main chunk [C]: in function 'xpcall' /usr/lib/prosody/core/modulemanager.lua:183: in function 'do_load_module' /usr/lib/prosody/core/modulemanager.lua:261: in function 'load' /usr/lib/prosody/core/modulemanager.lua:83: in function '?' /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75> (...tail calls...) /usr/lib/prosody/core/hostmanager.lua:108: in function 'activate' /usr/lib/prosody/core/hostmanager.lua:58: in function '?' /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75> (...tail calls...) /usr/lib/prosody/util/startup.lua:399: in function 'prepare_to_start' /usr/lib/prosody/util/startup.lua:635: in function 'f' /usr/lib/prosody/util/async.lua:139: in function 'func' /usr/lib/prosody/util/async.lua:127: in function </usr/lib/prosody/util/async.lua:125>
even if i try port 9000 same thing it seem that in older version of peertube it worked
9090 was an accident my fault, here is my plugin page
Sorry, my question was not specific enough. I was asking for a screenshot of the livechat plugin settings page (just click on "settings" on the livechat line from this screen.
I asked on mastodon for people using Peertube on Docker, to see if other people have the same issue. I'll tell you if it is working or not for other admins. I have no time to search for myself in the next days, sorry.
If you know how to do, please try to enable IPv6 on the host machine. Maybe it could work.
Okay ill work on ipv6 maybe peertube maker knows @Chocobozzz
9090 was an accident my fault, here is my plugin page
Sorry, my question was not specific enough. I was asking for a screenshot of the livechat plugin settings page (just click on "settings" on the livechat line from this screen.
Don't forget this screenshot please.
yes sir here is screen recording
@Chocobozzz are you able to help me with ipv6
yes sir here is screen recording
The video has been archived, I cannot see it anymore... Just paste 2 or 3 screenshot directly in your github reply (pasting a screenshot will automatically upload it).
@Chocobozzz are you able to help me with ipv6
I'm not sure yet if it is related to ipv6, I must first check your configuration. And please don't bother Chocobozzz about troubleshooting using this plugin, he is not involved in the dev process and has enough work to do on Peertube.
@ncamacho97 , can you also test this command:
cd /var/www/peertube-docker && docker-compose exec -u peertube peertube cat /etc/hosts
And paste the result.
Yes sir I can give me a sec to open my ssh on my phone in currently at work one sec and sorry about tagging Chocobozzz I just thought maybe he knows more about ipv6
Yes sir I can give me a sec to open my ssh on my phone in currently at work one sec and sorry about tagging Chocobozzz I just thought maybe he knows more about ipv6
Okay, someone give me access to a peertube-docker server to test. I can reproduce your issue. It seems that this is not an ipv6 issue. I'll try to find, but I can't say when. I'm actually really busy on other projects.
Okay brother I really appreciate you making a docker setup up just for me 💯🙏 give me a bit while I get the information you wanted and what's your Timezone I'm in Chicago
Okay brother I really appreciate you making a docker setup up just for me 100pray give me a bit while I get the information you wanted and what's your Timezone I'm in Chicago
Forget information I asked you. I can reproduce, there is really a bug. I'll search on my own.
My timezone: France (UTC+2)
Okay I used your docker image 4.2.0 thanks alot bro I'm at work and ssh on phone isn't easy lol again I really appreciate your efforts to help me
I made some tests. I can confirm it is NOT an IPV6 issue. The real issue is this:
Danger, Will Robinson! Prosody doesn't need to be run as root, so don't do it!
I'm surprised: Prosody should be launched by a «peertube» user, not root. Something must have changed in Docker or in the Peertube Docker image. I'll search today.
Yes I do remember see in the container that it was trying to run it as root for some odd reason could it be that I'm root maybe if I made a new user with root privileges maybe it'll work
I have a temporary dirty fix. This is not an ideal solution, but it works.
cd /var/www/peertube-docker
Then edit the file docker-volume/data/plugins/node_modules/peertube-plugin-livechat/dist/server/lib/prosody/config/content.js
Line 87, just after this.global.set('daemonize', true);
, add: this.global.set('run_as_root', true);
Then:
docker-compose down
docker-compose up -d
Then go to the livechat plugin settings page, search for the field Peertube url for API calls
, and set the value to http://localhost:9000
.
Save the settings.
It should then work.
If not, open again docker-volume/data/plugins/node_modules/peertube-plugin-livechat/dist/server/lib/prosody/config/content.js
, and remove all , '::1'
. Then again docker-compose down, up, and save the settings.
It's a solution for the next days, I'll come with a nicer one later this week.
Thanks alot brother really appreciate your time 💯🙏
hey question are you thinking of making a super chat feature it be lovely and yes this works really appreciate it
Great if it works!
What do you mean with «super chat» ? I have many features in mind, but it will depend on the funding I can get.
super chat like on YouTube so people can sub to the channel basically donation
how much are you talking to developing plugins
super chat like on YouTube so people can sub to the channel basically donation
I have to take a look.
@ncamacho97 , the bug was on the official Peertube Docker image. Peertube was launch by the root user, instead of the peertube user. This was fixed in v4.2.1: https://github.com/Chocobozzz/PeerTube/commit/5b2ede7d5519bf7d99854c445a8a9a2c8c591bfb (thanks @Chocobozzz) I just released the new image.
To upgrade: First, uninstall the plugin (to remove your modification, and for another reason that I will explain at the end of this comment). Then:
cd /var/www/peertube-docker
docker-compose pull
docker-compose down -v
docker-compose up -d
Then, re-install the plugin.
Now it should work.
I think there is still a problem, and I send a mail to @Chocobozzz to tell him. I'm waiting for his answer. As Peertube was wrongly launched with the root user, plugins and videos added belongs to the root user, instead of the peertube user. So trying to change these files will fail. Maybe I'm wrong and Docker handles this correctly, I don't know.
hey so i used docker image Chocobozzz images but that dose not have prosody or converseJS in his image maybe update yours on dockerhub ? now i might have to use your 4.2.0 because of prosody and converseJS
hey so i used docker image Chocobozzz images but that dose not have prosody or converseJS in his image maybe update yours on dockerhub ? now i might have to use your 4.2.0 because of prosody and converseJS
I never said you have to use the official image. I released a new image, based on the new v4.2.1 released yesterday. The bug was in the official v4.2.0, and fixed by Chocobozzz in v4.2.1.
So, change again to my image, and just follow the steps I gave (docker-compose pull
to update the image, etc.)
my error sorry
Hello, I'm having issues with live chat plugin I've changed the docker-compose.yml from chocobozzz/peertube:production-bullseye to johnxlivingston/peertubelivechat:production-bullseye and when i go live chat wont load!
https://syop.xyz/plugins/livechat/5.7.0/router/settings/diagnostic