Distributed Deployment¶
Sometimes you might encounter this situation: your phone is at home but you’re away, how can you use it? You can achieve distributed deployment through FIRERPA’s built-in Frp or OpenVPN client, allowing you to connect to distributed devices from any location. Both solutions require you to have a public server and configure the relevant server-side software for normal use. The subsequent documentation describes how to deploy Frp and OpenVPN servers. You can also choose to use the free Xinghuo Cluster to implement this function with one click.
Danger
The operations in this chapter may expose your phone to the public network, increasing security risks. Please read carefully.
This chapter will not mention basic operations such as how to open/close firewall ports. We assume you understand and have completed the settings as required, and we assume you have some knowledge of Frp and OpenVPN. We provide detailed instructions on how to deploy these two servers in this document and subsequent chapters. If you choose to deploy on your own, we strongly recommend using the OpenVPN networking method.
Forwarding to Internal Ports via Frp¶
You need to first download the server program from fatedier/frp and strictly use the following command to start it. You can modify the port and token as needed. The frps version needs to be > v0.45.0.
frps --token lamda --bind_addr 0.0.0.0 --bind_port 6009 --proxy_bind_addr 127.0.0.1 --allow_ports 10000-15000
Based on the command, write the properties.local configuration items as follows:
fwd.host=Your server's public address
fwd.port=6009
fwd.rport=Forwarding destination port (should be within the allow_ports range)
fwd.token=lamda
fwd.protocol=tcp
fwd.enable=true
Append or write the above configuration to properties.local, then restart the FIRERPA service.
Forwarding to Public Network Ports via Frp¶
If you want to connect to the device from anywhere, we don’t recommend doing this for security reasons. If you really need to use it this way, we suggest using the OpenVPN-related function to place the device and your computer on the same network segment for access.
If you still plan to use the above frp method to achieve arbitrary access, please first ensure that the FIRERPA service is started with an encryption certificate, and change --proxy_bind_addr 127.0.0.1
in the above frps startup command to --proxy_bind_addr 0.0.0.0
. This will cause the 12345
port in the above example to be directly bound to the public network. If you start FIRERPA without an encryption certificate, anyone will be able to access it, which is extremely dangerous. Please be prepared for the possibility that your data may be maliciously accessed and damaged.
Connecting to Devices Forwarded via Frp¶
Because the forwarded port in the above document is bound to the server’s 127.0.0.1
, the following content needs to be verified on the public server where frps is deployed. We assume your fwd.rport
is port 12345
. The following demonstrates how to connect to the device using the Python library.
from lamda.client import *
d = Device("127.0.0.1", port=12345)
You can also open http?s://127.0.0.1:12345
in your browser on the server to access the device’s remote desktop.
Implementation via OpenVPN Networking¶
Please check the relevant chapter on how to deploy an OpenVPN server to learn how to connect devices to the OpenVPN network.
Connecting to Devices Using OpenVPN Networking¶
Devices connected through OpenVPN networking are no different from your normal usage process. You just need to join your personal computer to this OpenVPN network to directly access the device through its OpenVPN private address. You can download the OpenVPN Connect
client from the official OpenVPN website openvpn.net/client to join the same network.
Implementation via Xinghuo Platform Networking¶
You can follow our official WeChat account Device Farm, and get a free Xinghuo platform usage code from the subscription menu entry in our official account. Then follow the relevant tutorials in the articles or videos published in the official account history to install and use the platform.

