services:
  rustdesk-server:
    container_name: ${CONTAINER_NAME}
    restart: always
    networks:
      - 1panel-network
    ports:
      - "${NAT_TEST_PORT}:21115" #NAT类型测试
      - "${HBBS_PORT}:21116" # 自定义 hbbs 映射端口
      - "${HBBS_PORT}:21116/udp" #自定义 hbbs 映射端口
      - "${HBBR_PORT}:21117" # 自定义 hbbr 映射端口
      - "${WEB_CLIENT_PORT1}:21118" #网页客户端支持端口
      - "${WEB_CLIENT_PORT2}:21119" #网页客户端支持端口
    volumes:
      - "./data/hbbs:/data" # 自定义挂载目录
    environment:
      - "RELAY=${HOST_ADDRESS}:${HBBR_PORT}"
      - "ENCRYPTED_ONLY=1"
    image: rustdesk/rustdesk-server-s6:latest
    labels:  
      createdBy: "Apps"

networks:  
  1panel-network:  
    external: true
