#3 telebit not work after connect telebit-relay server

Open
opened 10 months ago by supermanhuyu · 3 comments

hi, i get some error when i use telebit-relay. can you help me ?

after install telebit-relay with the command: curl -fsSL https://get.telebit.cloud/relay | bash

and modified the config file: /opt/telebit-relay/etc/telebit-relay.yml.

run relay with : systemctl restart telebit-relay or Manually run it , i get this result


root@telebit:~# /opt/telebit-relay/bin/node /opt/telebit-relay/bin/telebit-relay.js --config /opt/telebit-relay/etc/telebit-relay.yml
[DEBUG] no extensions loaded { Error: Cannot find module '../lib/extensions'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
    at Function.Module._load (internal/modules/cjs/loader.js:562:25)
    at Module.require (internal/modules/cjs/loader.js:692:17)
    at require (internal/modules/cjs/helpers.js:25:18)
    at applyConfig (/opt/telebit-relay/bin/telebit-relay.js:141:24)
    at /opt/telebit-relay/bin/telebit-relay.js:230:3
    at FSReqWrap.readFileAfterClose [as oncomplete] (internal/fs/read_file_context.js:53:3) code: 'MODULE_NOT_FOUND' }
[cli] Listening for TCP connections on 80
[cli] Listening for TCP connections on 443
command: add_token [ 'a24b2633bf6ad7092c082c3c4916df3b' ]
[addToken] a24b2633bf6ad7092c082c3c4916df3b

[relay.js] rawAuth
a24b2633bf6ad7092c082c3c4916df3b

[relay.js] authnToken
null
[debug] [http] assume external
[dontkeepme] servername 45.76.79.161
[debug] [http] no device connected
command: add_token [ 'a24b2633bf6ad7092c082c3c4916df3b' ]
[addToken] a24b2633bf6ad7092c082c3c4916df3b

[relay.js] rawAuth
a24b2633bf6ad7092c082c3c4916df3b

[relay.js] authnToken
null



[ws] device hangup IPv6,::ffff:47.75.89.187,48966 connection closing


and my server config file


root@telebit:~# cat /opt/telebit-relay/etc/telebit-relay.yml
email: hooby@betterhu.com
secret: a24b2633bf6ad7092c082c3c4916df3b
servernames: [ betterhu.com ]
agree_tos: true
community_member: true
telemetry: true
vhost: /srv/www/:hostname
greenlock:
  version: 'draft-11'
  server: 'https://acme-v02.api.letsencrypt.org/directory'
  store:
    strategy: le-store-certbot
  config_dir: /opt/telebit-relay/etc/acme


my client config


$ cat /home/sg-ai/.config/telebit/telebitd.yml
sock: /home/sg-ai/.local/share/telebit/var/run/telebit.sock
root: /home/sg-ai/Applications/telebit
community_member: true
telemetry: true
newsletter: false
ssh_auto: false
servernames:
  betterhu.com:
    wildcard: true
    handler: /home/sg-ai/gitlab/aiortc/examples
ports: {}
email: hooby@betterhu.com
agree_tos: true
relay: betterhu.com
token: a24b2633bf6ad7092c082c3c4916df3b
secret: null


and run the command with client

$ /home/sg-ai/Applications/telebit/bin/node /home/sg-ai/Applications/telebit/bin/telebitd.js daemon --config /home/sg-ai/.config/telebit/telebitd.yml

telebit daemon v0.20.8

[info] connecting with stored token
[info] Listening for commands on /home/sg-ai/.local/share/telebit/var/run/telebit.sock
[debug] got wss url
[telebit:lib/remote.js] [connect] 'wss://betterhu.com'
[telebit:lib/remote.js] [open] connected to 'wss://betterhu.com'
[connect] relay established
[debug] success on raw start, keepAlive = true
failed re-adding token a24b2633bf6ad7092c082c3c4916df3b after reconnect {}

use telebit command

$ ./telebit http Public/
telebit remote v0.20.8 (--config '~/.config/telebit/telebit.yml')

> Serving /home/sg-ai/Public as https://betterhu.com

but it not works.

hi, i get some error when i use telebit-relay. can you help me ? after install telebit-relay with the command: `curl -fsSL https://get.telebit.cloud/relay | bash` and modified the config file: /opt/telebit-relay/etc/telebit-relay.yml. run relay with : `systemctl restart telebit-relay` or Manually run it , i get this result ``` root@telebit:~# /opt/telebit-relay/bin/node /opt/telebit-relay/bin/telebit-relay.js --config /opt/telebit-relay/etc/telebit-relay.yml [DEBUG] no extensions loaded { Error: Cannot find module '../lib/extensions' at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15) at Function.Module._load (internal/modules/cjs/loader.js:562:25) at Module.require (internal/modules/cjs/loader.js:692:17) at require (internal/modules/cjs/helpers.js:25:18) at applyConfig (/opt/telebit-relay/bin/telebit-relay.js:141:24) at /opt/telebit-relay/bin/telebit-relay.js:230:3 at FSReqWrap.readFileAfterClose [as oncomplete] (internal/fs/read_file_context.js:53:3) code: 'MODULE_NOT_FOUND' } [cli] Listening for TCP connections on 80 [cli] Listening for TCP connections on 443 command: add_token [ 'a24b2633bf6ad7092c082c3c4916df3b' ] [addToken] a24b2633bf6ad7092c082c3c4916df3b [relay.js] rawAuth a24b2633bf6ad7092c082c3c4916df3b [relay.js] authnToken null [debug] [http] assume external [dontkeepme] servername 45.76.79.161 [debug] [http] no device connected command: add_token [ 'a24b2633bf6ad7092c082c3c4916df3b' ] [addToken] a24b2633bf6ad7092c082c3c4916df3b [relay.js] rawAuth a24b2633bf6ad7092c082c3c4916df3b [relay.js] authnToken null [ws] device hangup IPv6,::ffff:47.75.89.187,48966 connection closing ``` and my server config file ``` root@telebit:~# cat /opt/telebit-relay/etc/telebit-relay.yml email: hooby@betterhu.com secret: a24b2633bf6ad7092c082c3c4916df3b servernames: [ betterhu.com ] agree_tos: true community_member: true telemetry: true vhost: /srv/www/:hostname greenlock: version: 'draft-11' server: 'https://acme-v02.api.letsencrypt.org/directory' store: strategy: le-store-certbot config_dir: /opt/telebit-relay/etc/acme ``` my client config ``` $ cat /home/sg-ai/.config/telebit/telebitd.yml sock: /home/sg-ai/.local/share/telebit/var/run/telebit.sock root: /home/sg-ai/Applications/telebit community_member: true telemetry: true newsletter: false ssh_auto: false servernames: betterhu.com: wildcard: true handler: /home/sg-ai/gitlab/aiortc/examples ports: {} email: hooby@betterhu.com agree_tos: true relay: betterhu.com token: a24b2633bf6ad7092c082c3c4916df3b secret: null ``` and run the command with client ``` $ /home/sg-ai/Applications/telebit/bin/node /home/sg-ai/Applications/telebit/bin/telebitd.js daemon --config /home/sg-ai/.config/telebit/telebitd.yml telebit daemon v0.20.8 [info] connecting with stored token [info] Listening for commands on /home/sg-ai/.local/share/telebit/var/run/telebit.sock [debug] got wss url [telebit:lib/remote.js] [connect] 'wss://betterhu.com' [telebit:lib/remote.js] [open] connected to 'wss://betterhu.com' [connect] relay established [debug] success on raw start, keepAlive = true failed re-adding token a24b2633bf6ad7092c082c3c4916df3b after reconnect {} ``` use telebit command ``` $ ./telebit http Public/ telebit remote v0.20.8 (--config '~/.config/telebit/telebit.yml') > Serving /home/sg-ai/Public as https://betterhu.com ``` but it not works.
coolaj86 commented 10 months ago
Owner

Thanks for the report.

We don't have update install instructions for the relay server yet and we don't have time to update and test them right now, so you'll have to use the official server https://telebit.cloud until we do.

Right now our efforts are focused on improving the Telebit Remote client.

Thanks for the report. We don't have update install instructions for the relay server yet and we don't have time to update and test them right now, so you'll have to use the official server https://telebit.cloud until we do. Right now our efforts are focused on improving the Telebit Remote client.

Hello, I am looking to use Telibit relay for a project I am working at my job. I would like to know if you had time to update the relay server. I don't want to use the servers you all provide us I want to use a raspberry pi for that.

Hello, I am looking to use Telibit relay for a project I am working at my job. I would like to know if you had time to update the relay server. I don't want to use the servers you all provide us I want to use a raspberry pi for that.
coolaj86 commented 3 months ago
Owner

@Code_Media I have not had time to update them. If you have the budget for it, I'd love to take it on as contract work.

If you are familiar with linux and node and willing to dig into the install process I can give you some guidance, and I really do want to have a simple process for running this on a Pi, I just don't have the free time for it right now (I haven't even had time to productize my service so that it can pay for itself).

@Code_Media I have not had time to update them. If you have the budget for it, I'd love to take it on as contract work. If you are familiar with linux and node and willing to dig into the install process I can give you some guidance, and I really do want to have a simple process for running this on a Pi, I just don't have the free time for it right now (I haven't even had time to productize my service so that it can pay for itself).
Sign in to join this conversation.
No Label
No Milestone
No Assignees
3 Participants
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
Cancel
Save
There is no content yet.