docker编排 (可以安装宝塔linux)
搭建中继服务器
services:
rustdesk_Y662:
image: rustdesk/rustdesk-server-s6:${VERSION}
# container_name: ${CONTAINER_NAME}
deploy:
resources:
limits:
cpus: ${CPUS}
memory: ${MEMORY_LIMIT}
environment:
- RELAY=${RUSTDESK_HOST_ADDR}:${RUSTDESK_PORT_HBBR}
- ENCRYPTED_ONLY=1
ports:
- ${HOST_IP}:${RUSTDESK_PORT_NAT}:21115
- ${HOST_IP}:${RUSTDESK_PORT_HBBS}:21116
- ${HOST_IP}:${RUSTDESK_PORT_HBBS}:21116/udp
- ${HOST_IP}:${RUSTDESK_PORT_HBBR}:21117
- ${HOST_IP}:${RUSTDESK_PORT_WEB_CLIENT_1}:21118
- ${HOST_IP}:${RUSTDESK_PORT_WEB_CLIENT_2}:21119
restart: always
volumes:
- ${APP_PATH}/data:/data
labels:
createdBy: "bt_apps"
networks:
- baota_net
networks:
baota_net:
external: true
搭建api服务器
networks:
rustdesk-net:
external: false
services:
rustdesk:
image: lejianwen/rustdesk-api:full-s6
ports:
- "27250:21114"
environment:
RELAY: "118.89.88.198:21117"
ENCRYPTED_ONLY: "1"
TZ: "Asia/Shanghai"
RUSTDESK_API_RUSTDESK_ID_SERVER: "【server_ip】:21116"
RUSTDESK_API_RUSTDESK_RELAY_SERVER: "【server_ip】:21117"
RUSTDESK_API_RUSTDESK_API_SERVER: "http://【server_ip】:27250"
volumes:
- /data/rustdesk/server:/data
- /data/rustdesk/server:/app/conf/data
- /data/rustdesk/api:/app/data
networks:
- rustdesk-net
restart: unless-stopped
```