欢迎来到尧图网

客户服务 关于我们

您的位置:首页 > 新闻 > 焦点 > docker 自建rustdesk服务器测试

docker 自建rustdesk服务器测试

2025/1/14 4:14:38 来源:https://blog.csdn.net/weixin_42771529/article/details/145094269  浏览:    关键词:docker 自建rustdesk服务器测试

参考https://blog.csdn.net/tootsy_you/article/details/130010564 

注意:

docker-compose.yml

version: '3'networks:rustdesk-net:external: falseservices:hbbs:container_name: hbbsports:- 21115:21115- 21116:21116- 21116:21116/udp- 21118:21118image: rustdesk/rustdesk-server:latestcommand: hbbs -r 10.73.30.241:21117volumes:- ./data:/rootnetworks:- rustdesk-netdepends_on:- hbbrrestart: unless-stoppedhbbr:container_name: hbbrports:- 21117:21117- 21119:21119image: rustdesk/rustdesk-server:latestcommand: hbbrvolumes:- ./data:/rootnetworks:- rustdesk-netrestart: unless-stopped

起动

kt@kt4028:~/rustdesk$ docker compose up -d
WARN[0000] /home/kt/rustdesk/docker-compose.yml: the attribute `version` is obsolete, it will be ignored, please remove it to avoid potential confusion 
[+] Running 3/3✔ Network rustdesk_rustdesk-net  Creat...                                 0.1s ✔ Container hbbr                 Started                                  0.3s ✔ Container hbbs                 Started                                  0.6s 
kt@kt4028:~/rustdesk$ docker ps -a
CONTAINER ID   IMAGE                             COMMAND                  CREATED          STATUS                    PORTS                                                                                                                                                                 NAMES
996219c21c99   rustdesk/rustdesk-server:latest   "hbbs -r 10.73.30.24…"   20 seconds ago   Up 19 seconds             0.0.0.0:21115-21116->21115-21116/tcp, :::21115-21116->21115-21116/tcp, 0.0.0.0:21118->21118/tcp, :::21118->21118/tcp, 0.0.0.0:21116->21116/udp, :::21116->21116/udp   hbbs
ac9ef80c7ad9   rustdesk/rustdesk-server:latest   "hbbr"                   20 seconds ago   Up 19 seconds             0.0.0.0:21117->21117/tcp, :::21117->21117/tcp, 0.0.0.0:21119->21119/tcp, :::21119->21119/tcp               

查看密码

kt@kt4028:~/rustdesk$ docker logs hbbs
[2025-01-12 08:13:33.181897 +00:00] INFO [src/common.rs:122] Private key comes from id_ed25519
[2025-01-12 08:13:33.181918 +00:00] INFO [src/rendezvous_server.rs:1205] Key: CV6jEZIB3HDnAbUPwtbdzrMzzZF6yxbaBuSlAUR5pNQ=
[2025-01-12 08:13:33.181924 +00:00] INFO [src/peer.rs:84] DB_URL=./db_v2.sqlite3
[2025-01-12 08:13:33.183226 +00:00] INFO [src/rendezvous_server.rs:99] serial=0
[2025-01-12 08:13:33.183246 +00:00] INFO [src/common.rs:46] rendezvous-servers=[]
[2025-01-12 08:13:33.183251 +00:00] INFO [src/rendezvous_server.rs:101] Listening on tcp/udp :21116
[2025-01-12 08:13:33.183256 +00:00] INFO [src/rendezvous_server.rs:102] Listening on tcp :21115, extra port for NAT test
[2025-01-12 08:13:33.183261 +00:00] INFO [src/rendezvous_server.rs:103] Listening on websocket :21118
[2025-01-12 08:13:33.183321 +00:00] INFO [libs/hbb_common/src/udp.rs:36] Receive buf size of udp [::]:21116: Ok(212992)
[2025-01-12 08:13:33.183434 +00:00] INFO [src/rendezvous_server.rs:138] mask: None
[2025-01-12 08:13:33.183448 +00:00] INFO [src/rendezvous_server.rs:139] local-ip: ""
[2025-01-12 08:13:33.183464 +00:00] INFO [src/common.rs:46] relay-servers=["10.73.30.241:21117"]
[2025-01-12 08:13:33.183586 +00:00] INFO [src/rendezvous_server.rs:153] ALWAYS_USE_RELAY=N
[2025-01-12 08:13:33.183606 +00:00] INFO [src/rendezvous_server.rs:185] Start
[2025-01-12 08:13:33.183684 +00:00] INFO [libs/hbb_common/src/udp.rs:36] Receive buf size of udp [::]:0: Ok(212992)
kt@kt4028:~/rustdesk$ 

无头运行本地ubuntu,被控端

rustdesk --start-service

 根据提示。一次不行就再启动一次。被控制端ubuntu。

控制端win

 

成功

这会好了。在局网中可自由了。

版权声明:

本网仅为发布的内容提供存储空间,不对发表、转载的内容提供任何形式的保证。凡本网注明“来源:XXX网络”的作品,均转载自其它媒体,著作权归作者所有,商业转载请联系作者获得授权,非商业转载请注明出处。

我们尊重并感谢每一位作者,均已注明文章来源和作者。如因作品内容、版权或其它问题,请及时与我们联系,联系邮箱:809451989@qq.com,投稿邮箱:809451989@qq.com