Introduction
由324位工程师开发的RustDesk软件。到目前为止(2025年5月23日,20时24分)累计收获 88.8k⭐
Build • Docker • Structure • Snapshot
[ 乌克兰语] | [ 捷克语] | [ 中文] | [ 匈牙利语] | [ 西班牙语] | [ 波斯语] | [ 法语] | [ 德语] | [ 波兰语] | [ 印度尼西亚语] | [ 芬兰语] | [ 马拉雅拉姆语] | [ 日语] | [ 荷兰语] | [ 意大利语] | [ 俄语] | [ 巴西葡萄牙语] | [ 世界语] | [ 韩语] | [ 阿拉伯语] | [ 越南语] | [ 丹麦语] | [ 希腊语] | [ 土耳其语] | [ 挪威语]
Caution 注意
Misuse Disclaimer: 使用免责声明:
The developers of RustDesk do not condone or support any unethical or illegal use of this software. Misuse, such as unauthorized access, control or invasion of privacy, is strictly against our guidelines. The authors are not responsible for any misuse of the application.
RustDesk 的开发者不赞成或支持任何不道德或非法使用本软件。滥用,如未经授权的访问、控制或侵犯隐私,严格违反我们的准则。作者对应用程序的任何滥用不承担责任。八进制论坛也不承担责任
Chat with us: Discord | Twitter | Reddit | YouTube
Yet another remote desktop software, written in Rust. Works out of the box, no configuration required. You have full control of your data, with no concerns about security. You can use our rendezvous/relay server, set up your own, or write your own rendezvous/relay server.
又一个远程桌面软件,使用 Rust 编写。开箱即用,无需配置。您可以完全控制您的数据,无需担心安全问题。您可以使用我们的中继服务器,设置自己的,或编写自己的中继服务器。
RustDesk welcomes contribution from everyone. See CONTRIBUTING.md for help getting started.
RustDesk 欢迎大家的贡献。请参阅 CONTRIBUTING.md 获取入门帮助。
Dependencies
Desktop versions use Flutter or Sciter (deprecated) for GUI, this tutorial is for Sciter only, since it is easier and more friendly to start. Check out our CI for building Flutter version.
桌面版本使用 Flutter 或 Sciter(已弃用)进行 GUI 开发,本教程仅适用于 Sciter,因为它更容易和更友好。请查看我们的 CI 以构建 Flutter 版本。
Please download Sciter dynamic library yourself.
请自行下载 Sciter 动态库。
Raw steps to build
Prepare your Rust development env and C++ build env
准备您的 Rust 开发环境和 C++ 构建环境Install vcpkg, and set
VCPKG_ROOT
env variable correctly
安装 vcpkg,并正确设置VCPKG_ROOT
环境变量Windows: vcpkg install libvpx:x64-windows-static libyuv:x64-windows-static opus:x64-windows-static aom:x64-windows-static
Linux/macOS: vcpkg install libvpx libyuv opus aom
run
cargo run
Build
How to build on Linux
Ubuntu 18 (Debian 10)
sudo apt install -y zip g++ gcc git curl wget nasm yasm libgtk-3-dev clang libxcb-randr0-dev libxdo-dev \
libxfixes-dev libxcb-shape0-dev libxcb-xfixes0-dev libasound2-dev libpulse-dev cmake make \
libclang-dev ninja-build libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev libpam0g-dev
openSUSE Tumbleweed
sudo zypper install gcc-c++ git curl wget nasm yasm gcc gtk3-devel clang libxcb-devel libXfixes-devel cmake alsa-lib-devel gstreamer-devel gstreamer-plugins-base-devel xdotool-devel pam-devel
Fedora 28 (CentOS 8)
sudo yum -y install gcc-c++ git curl wget nasm yasm gcc gtk3-devel clang libxcb-devel libxdo-devel libXfixes-devel pulseaudio-libs-devel cmake alsa-lib-devel gstreamer1-devel gstreamer1-plugins-base-devel pam-devel
Arch (Manjaro)
sudo pacman -Syu --needed unzip git cmake gcc curl wget yasm nasm zip make pkg-config clang gtk3 xdotool libxcb libxfixes alsa-lib pipewire
Install vcpkg
git clone https://github.com/microsoft/vcpkg
cd vcpkg
git checkout 2023.04.15
cd ..
vcpkg/bootstrap-vcpkg.sh
export VCPKG_ROOT=$HOME/vcpkg
vcpkg/vcpkg install libvpx libyuv opus aom
Fix libvpx (For Fedora)
cd vcpkg/buildtrees/libvpx/src
cd *
./configure
sed -i 's/CFLAGS+=-I/CFLAGS+=-fPIC -I/g' Makefile
sed -i 's/CXXFLAGS+=-I/CXXFLAGS+=-fPIC -I/g' Makefile
make
cp libvpx.a $HOME/vcpkg/installed/x64-linux/lib/
cd
Build
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source $HOME/.cargo/env
git clone --recurse-submodules https://github.com/rustdesk/rustdesk
cd rustdesk
mkdir -p target/debug
wget https://raw.githubusercontent.com/c-smile/sciter-sdk/master/bin.lnx/x64/libsciter-gtk.so
mv libsciter-gtk.so target/debug
VCPKG_ROOT=$HOME/vcpkg cargo run
How to build with Docker
Begin by cloning the repository and building the Docker container:
先克隆仓库并构建 Docker 容器:
git clone https://github.com/rustdesk/rustdesk
cd rustdesk
git submodule update --init --recursive
docker build -t "rustdesk-builder" .
Then, each time you need to build the application, run the following command:
然后,每次您需要构建应用程序时,请运行以下命令:
docker run --rm -it -v $PWD:/home/user/rustdesk -v rustdesk-git-cache:/home/user/.cargo/git -v rustdesk-registry-cache:/home/user/.cargo/registry -e PUID="$(id -u)" -e PGID="$(id -g)" rustdesk-builder
Note that the first build may take longer before dependencies are cached, subsequent builds will be faster. Additionally, if you need to specify different arguments to the build command, you may do so at the end of the command in the <OPTIONAL-ARGS>
position. For instance, if you wanted to build an optimized release version, you would run the command above followed by --release
. The resulting executable will be available in the target folder on your system, and can be run with:
请注意,第一次构建可能需要更长时间,因为依赖项尚未缓存,后续构建将更快。此外,如果您需要为构建命令指定不同的参数,可以在命令末尾的 <OPTIONAL-ARGS>
位置指定。例如,如果您想要构建一个优化的发布版本,您需要运行上述命令,然后跟以 --release
。生成的可执行文件将位于您的系统目标文件夹中,并且可以使用:
target/debug/rustdesk
Or, if you're running a release executable:
或者,如果你正在运行一个发布可执行文件:
target/release/rustdesk
Please ensure that you are running these commands from the root of the RustDesk repository, otherwise the application might not be able to find the required resources. Also note that other cargo subcommands such as install
or run
are not currently supported via this method as they would install or run the program inside the container instead of the host.
请确保您从 RustDesk 仓库的根目录运行这些命令,否则应用程序可能无法找到所需的资源。此外,请注意, install
或 run
等其他 cargo 子命令当前不通过此方法支持,因为它们会在容器内而不是主机内安装或运行程序。
File Structure 文件结构
libs/hbb_common: video codec, config, tcp/udp wrapper, protobuf, fs functions for file transfer, and some other utility functions
libs/hbb_common:视频编解码器、配置、tcp/udp 包装器、protobuf、文件传输的文件系统函数以及其他一些实用函数libs/scrap: screen capture
libs/scrap: 屏幕截图libs/enigo: platform specific keyboard/mouse control
libs/enigo: 平台特定键盘/鼠标控制libs/clipboard: file copy and paste implementation for Windows, Linux, macOS.
libs/clipboard: Windows、Linux、macOS 的文件复制粘贴实现。src/ui: obsolete Sciter UI (deprecated)
src/ui: 已弃用的 Sciter UI (已弃用)src/server: audio/clipboard/input/video services, and network connections
src/server: 音频/剪贴板/输入/视频服务,以及网络连接src/client.rs: start a peer connection
src/client.rs: 开始一个对等连接src/rendezvous_mediator.rs: Communicate with rustdesk-server, wait for remote direct (TCP hole punching) or relayed connection
src/rendezvous_mediator.rs: 与 rustdesk-server 通信,等待远程直接(TCP 穿孔)或中继连接src/platform: platform specific code
src/platform: 平台特定代码flutter: Flutter code for desktop and mobile
Flutter:用于桌面和移动端的 Flutter 代码flutter/web/js: JavaScript for Flutter web client
flutter/web/js:用于 Flutter 网页客户端的 JavaScript
Screenshots
The server is deployed on the pagoda panel 服务端在宝塔面板上部署
进入 Docker面板 -> 打开“应用商店” -> 搜索"rustdesk" -> 选择RustDesk “安装”
进入 容器界面 -> 点击“更多” -> 点击“日志"选项 -> 找到 key 值 复制
进入 安全界面 -> 开放 TCP:21116~21117 端口 和 UDP:21116端口
Client Configuration 客户端配置
打开 RustDesk 应用程序,在主界面里 点击三个点 -> 进入 设置界面 的 网络栏 点击 “ID/中继服务器",在弹出的界面框中 填写 服务器IP 和 Key值。完成这一步就大功告成了!
Related links 相关链接
rustdesk-1.4.0-x86_64_install.zip -> RustDesk 安装程序 电脑端
rustdesk-1.4.0-x86_64.exe -> RustDesk 便捷版本 电脑端 提取码:bpbc
rustdesk-1.4.0-universal-signed.apk -> Android端 提取码:a6b2
评论区