Fix mjolnir, matrix admin thingy #135

Closed
opened 2024-08-22 23:21:00 +02:00 by oysteikt · 5 comments
Owner

where were you when mjolnir die

i was at house eating dorito when @danio ring

“mjolnir is kil”

“no”


Seems to be targeting a non-existent address? There is nothing bound to port 8008 on bicep.

Aug 22 04:47:08 bicep systemd[1]: Starting mjolnir - a moderation tool for Matrix...
Aug 22 04:47:08 bicep systemd[1]: Started mjolnir - a moderation tool for Matrix.
Aug 22 04:47:10 bicep mjolnir[2311225]: Thu, 22 Aug 2024 02:47:10 GMT [INFO] [index] Starting bot...
Aug 22 04:47:10 bicep mjolnir[2311225]: Thu, 22 Aug 2024 02:47:10 GMT [ERROR] [MatrixHttpClient] (REQ-1) Error: connect ECONNREFUSED 127.0.0.1:8008
Aug 22 04:47:10 bicep mjolnir[2311225]:     at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1606:16) {
Aug 22 04:47:10 bicep mjolnir[2311225]:   errno: -111,
Aug 22 04:47:10 bicep mjolnir[2311225]:   code: 'ECONNREFUSED',
Aug 22 04:47:10 bicep mjolnir[2311225]:   syscall: 'connect',
Aug 22 04:47:10 bicep mjolnir[2311225]:   address: '127.0.0.1',
Aug 22 04:47:10 bicep mjolnir[2311225]:   port: 8008
Aug 22 04:47:10 bicep mjolnir[2311225]: }
Aug 22 04:47:10 bicep mjolnir[2311225]: Failed to setup mjolnir from the config /var/lib/mjolnir: Error: connect ECONNREFUSED 127.0.0.1:8008
Aug 22 04:47:10 bicep mjolnir[2311225]: node:internal/process/promises:391
Aug 22 04:47:10 bicep mjolnir[2311225]:     triggerUncaughtException(err, true /* fromPromise */);
Aug 22 04:47:10 bicep mjolnir[2311225]:     ^
Aug 22 04:47:10 bicep mjolnir[2311225]: Error: connect ECONNREFUSED 127.0.0.1:8008
Aug 22 04:47:10 bicep mjolnir[2311225]:     at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1606:16) {
Aug 22 04:47:10 bicep mjolnir[2311225]:   errno: -111,
Aug 22 04:47:10 bicep mjolnir[2311225]:   code: 'ECONNREFUSED',
Aug 22 04:47:10 bicep mjolnir[2311225]:   syscall: 'connect',
Aug 22 04:47:10 bicep mjolnir[2311225]:   address: '127.0.0.1',
Aug 22 04:47:10 bicep mjolnir[2311225]:   port: 8008
Aug 22 04:47:10 bicep mjolnir[2311225]: }
Aug 22 04:47:10 bicep mjolnir[2311225]: Node.js v20.15.1
Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Main process exited, code=exited, status=1/FAILURE
Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Failed with result 'exit-code'.
Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Consumed 2.161s CPU time, received 40B IP traffic, sent 60B IP traffic.
Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Scheduled restart job, restart counter is at 9.
Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Start request repeated too quickly.
Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Failed with result 'exit-code'.
Aug 22 04:47:10 bicep systemd[1]: Failed to start mjolnir - a moderation tool for Matrix.
where were you when mjolnir die i was at house eating dorito when @danio ring “mjolnir is kil” “no” --- Seems to be targeting a non-existent address? There is nothing bound to port 8008 on bicep. ``` Aug 22 04:47:08 bicep systemd[1]: Starting mjolnir - a moderation tool for Matrix... Aug 22 04:47:08 bicep systemd[1]: Started mjolnir - a moderation tool for Matrix. Aug 22 04:47:10 bicep mjolnir[2311225]: Thu, 22 Aug 2024 02:47:10 GMT [INFO] [index] Starting bot... Aug 22 04:47:10 bicep mjolnir[2311225]: Thu, 22 Aug 2024 02:47:10 GMT [ERROR] [MatrixHttpClient] (REQ-1) Error: connect ECONNREFUSED 127.0.0.1:8008 Aug 22 04:47:10 bicep mjolnir[2311225]: at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1606:16) { Aug 22 04:47:10 bicep mjolnir[2311225]: errno: -111, Aug 22 04:47:10 bicep mjolnir[2311225]: code: 'ECONNREFUSED', Aug 22 04:47:10 bicep mjolnir[2311225]: syscall: 'connect', Aug 22 04:47:10 bicep mjolnir[2311225]: address: '127.0.0.1', Aug 22 04:47:10 bicep mjolnir[2311225]: port: 8008 Aug 22 04:47:10 bicep mjolnir[2311225]: } Aug 22 04:47:10 bicep mjolnir[2311225]: Failed to setup mjolnir from the config /var/lib/mjolnir: Error: connect ECONNREFUSED 127.0.0.1:8008 Aug 22 04:47:10 bicep mjolnir[2311225]: node:internal/process/promises:391 Aug 22 04:47:10 bicep mjolnir[2311225]: triggerUncaughtException(err, true /* fromPromise */); Aug 22 04:47:10 bicep mjolnir[2311225]: ^ Aug 22 04:47:10 bicep mjolnir[2311225]: Error: connect ECONNREFUSED 127.0.0.1:8008 Aug 22 04:47:10 bicep mjolnir[2311225]: at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1606:16) { Aug 22 04:47:10 bicep mjolnir[2311225]: errno: -111, Aug 22 04:47:10 bicep mjolnir[2311225]: code: 'ECONNREFUSED', Aug 22 04:47:10 bicep mjolnir[2311225]: syscall: 'connect', Aug 22 04:47:10 bicep mjolnir[2311225]: address: '127.0.0.1', Aug 22 04:47:10 bicep mjolnir[2311225]: port: 8008 Aug 22 04:47:10 bicep mjolnir[2311225]: } Aug 22 04:47:10 bicep mjolnir[2311225]: Node.js v20.15.1 Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Main process exited, code=exited, status=1/FAILURE Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Failed with result 'exit-code'. Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Consumed 2.161s CPU time, received 40B IP traffic, sent 60B IP traffic. Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Scheduled restart job, restart counter is at 9. Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Start request repeated too quickly. Aug 22 04:47:10 bicep systemd[1]: mjolnir.service: Failed with result 'exit-code'. Aug 22 04:47:10 bicep systemd[1]: Failed to start mjolnir - a moderation tool for Matrix. ```
oysteikt added the
crash report
nixos
bug
labels 2024-08-22 23:21:00 +02:00
oysteikt added this to the Kanban project 2024-08-22 23:21:00 +02:00
Owner
https://github.com/the-draupnir-project/Draupnir
Owner

I believe this can be set to the public-facing hostname, e.g. homeserverUrl = "https://matrix.pvv.ntnu.no", like the example at 797f7dc49e/nixos/modules/services/matrix/mjolnir.nix (L72).
This will add another loop of nginx+tls in the communications between synapse and mjolnir, but will be functional and portable.

I believe this can be set to the public-facing hostname, e.g. `homeserverUrl = "https://matrix.pvv.ntnu.no"`, like the example at https://github.com/NixOS/nixpkgs/blob/797f7dc49e0bc7fab4b57c021cdf68f595e47841/nixos/modules/services/matrix/mjolnir.nix#L72. This will add another loop of nginx+tls in the communications between synapse and mjolnir, but will be functional and portable.
Owner

It can't, since it makes use of /_synapse/admin which is not exposed over nginx

It can't, since it makes use of `/_synapse/admin` which is not exposed over nginx
danio was assigned by oysteikt 2024-08-26 18:26:34 +02:00
Author
Owner

Fixy bixy

Fixy bixy
Owner

For reference; Fixed in 914eb35c5a

For reference; Fixed in https://git.pvv.ntnu.no/Drift/pvv-nixos-config/commit/914eb35c5aff76ef25264807ff21ddf4a0d45af7
Sign in to join this conversation.
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Drift/issues#135
No description provided.