Skip to content

Commit

Permalink
Merge branch 'Clansty:rainbowcat' into rainbowcat
Browse files Browse the repository at this point in the history
  • Loading branch information
Nofated095 authored Nov 30, 2023
2 parents b534fe6 + e53df68 commit 574771d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,6 @@ services:
# 如果需要通过代理联网,那么设置下面两个变量
#- PROXY_IP=
#- PROXY_PORT=
# 代理联网认证,有需要请修改下面两个变量
#- PROXY_USERNAME=
#- PROXY_PASSWORD=
2 changes: 2 additions & 0 deletions src/client/Telegram.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ export default class Telegram {
socksType: 5,
ip: process.env.PROXY_IP,
port: parseInt(process.env.PROXY_PORT),
...(process.env.PROXY_USERNAME && { username: process.env.PROXY_USERNAME }),
...(process.env.PROXY_PASSWORD && { password: process.env.PROXY_PASSWORD }),
} : undefined,
autoReconnect: true,
networkSocket: process.env.TG_CONNECTION === 'websocket' ? PromisedWebSockets : PromisedNetSockets,
Expand Down

0 comments on commit 574771d

Please sign in to comment.