Running applications in Genymotion on a local network

I have two machines running on the same network. I use one machine for development, and another - various Android emulators.

I need to run applications on an emulator running on another PC from a development computer. Something like the launch command in the Android studio should make the installation of the application in Genymotion running on another PC.

Possible? Any ideas?

+6
source share
4 answers

It is possible. First you need to open your Genymotion devices on your local network. To do this, create the entire device that you want to run on a dedicated computer. Then open VirtualBox locally and for each device do the following:

  • Go to Settings> Network.
  • Open Adapter 2
  • Change the "Attached to" parameter to the "Bridged Adapter" (by default it is set to NAT)
  • Click OK

Then you need to get the local IP address of the device. You can get it by running the following command:

adb shell "ifconfig | awk '/inet addr/{print substr(\$2,6)}' | awk 'NR==2'" 

When all this is done, go back to your development PC. Open a terminal and enter for each of your remote Genymotion devices:

 adb connect <DEVICE_IP> 

This way you connect the local adb deamon to the remote devices.

Now you can control your remote Genymotion devices as if they were local. You can run adb install to install the APK remotely.

+2
source

Alternatively download WiFi ADB Adapter - Debugging by Air apk. Install it in your genymotion emulator. Turn on adb to connect it.

You cannot find ip: 5555 on the emulator application launch screen. Using this ip, you can connect any computer running on the same local network.

0
source

Be simple "try port forwarding." I used the TCPPortForward tool for this.

You can do it:

  • Get the IP address and port of a Genymotion emulator: adb devices

  • Get the IP address of the device assigned to you via Lan: ipconfig

  • Move <EMULATOR_IP:PORT> to <DEVICE_LAN_IP:PORT> using any tool such as TCPPortForward . Here is a screenshot of TCPPortForward Click here

Finally, on a remote start device

 adb connect <DEVICE_IP>:<PORT> 

You can also display different ports for multiple emulators from the same IP address.

All the best.

0
source

You can directly use the WiFi adb app in genemotion and use its URL for your system.

0
source

All Articles