gmsaas command line tool

Description

gmsaas is a command line interface for Genymotion Cloud SaaS.

Requirements

  • Python
  • pip3
  • Android SDK

Installation

pip3 install gmsaas

Configuration

Two steps are required to use gmsaas properly:

  • Configure the path to your Android SDK:
gmsaas config set android-sdk-path <sdk_path>
  • Authenticate with:
gmsaas auth login <email>

The --help option

This option is suitable for every gmsaas commands. It will provide you with all the supported commands, subcommands, options, and a quick explanation of what those do.

Commands

List recipes

gmsaas recipes list

A recipe is a template with a given Android version, display size, density and specifications (CPU, memory, storage) which generally match those of a real device.

Start an instance

gmsaas instances start <recipe_uuid> <name> [--no-wait]

Creates and start an instance based on the specified <recipe_uuid> recipe (cf. previous section). <name> is the name you wish to give to the instance. The command returns to shell once the instance is started, unless the --no-wait option has been set. In both cases the <instance_uuid> is printed on standard output.

Please note that you need to use the <instance_uuid> to refer to an instance when issuing commands via gmsaas. <name> is only use as a tag for convenience.

Connect an instance to ADB

gmsaas instances adbconnect <instance_uuid> [--adb-serial-port PORT]

Connects a running instance to ADB. The command returns to shell once ADB is connected. If the --adb-serial-port <PORT> option is set, the instance will be connected to ADB on localhost:<PORT>.

List running instances

gmsaas instances list

Lists all running instances. This also provides the ADB serial used if the instance is connected to ADB.

Stop an instance

gmsaas instances stop <instance_uuid> [--no-wait]

Stops the specified instance. The command returns to shell once the instance is fully stopped, unless the --no-wait option is set.

Instances launched with gmsaas will not stop until this command is issued, or it is stopped from the Web user interface. If you forget to do so, your credit will be deducted as long as the instance is running and you may get extra charges.

Bash/Zsh auto-completion

gmsaas supports Bash and Zsh auto-completion. To activate it, you need to inform your shell that completion is available.

For Bash, add this to your .bashrc:

eval "$(_GMSAAS_COMPLETE=source gmsaas)"

For Zsh, add this to your .zshrc:

eval "$(_GMSAAS_COMPLETE=source_zsh gmsaas)"

You must type at least one dash to complete command-line options.

Issues

Whatever your problem is, the Support Team will need logs to speed up the investigations. To generate them:

  1. Reproduce your issue
  2. Run gmsaas logzip: an archive named gmsaas-logs-YYYYMMDD-HHMMSS.zip will be created in the current directory
  3. Contact us here, don't forget to attach the logs archive