Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save netojose/892ade25460aaf8f0babdf4a0c0616b6 to your computer and use it in GitHub Desktop.
Save netojose/892ade25460aaf8f0babdf4a0c0616b6 to your computer and use it in GitHub Desktop.
Setup genymotion to access docker container.md
1.Open the commandline and run the following commands to edit the hosts file:
adb root
adb remount
adb pull /system/etc/hosts hosts
2.The hosts file should now be present in the folder where you excecuted the pull command. Edit the file with a text editor and add the sites you want to access. For example i added:
10.0.3.2        my-virtualhost.dev

LEAVE A EMPTY LINE AT THE END OF FILE

3.Send the hosts file back to the emulator
adb push hosts /system/etc/hosts
4.Browse to your site in the emulator browser. For example: my-virtualhost.dev You should see your homestead site now!

What to try if site is not reached from browser

  1. Check that you added an empty line after the last site in the hosts file.
  2. Close and reopen the emulator browser
  3. Restart the emulator
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment