How do I use gmsaas in a Jenkins pipeline to start Android virtual devices?
gmsaas can start Genymotion SaaS devices in CI, and the documented flow is to authenticate, start the instance, connect it to ADB, run your tests, then stop it. The Jenkins integration is explicitly supported in the automation docs via the Automation Features page and the Jenkins tutorial.
In a Jenkins pipeline, the usual sequence is:
1. Create an API token.
2. Install and set up gmsaas.
3. Authenticate with:
gmsaas auth token <token>
4. Start a device:
gmsaas instances start <RECIPE_UUID> <INSTANCE_NAME>
5. Connect it to ADB:
gmsaas instances adbconnect <INSTANCE_NAME> [--adb-serial-port <VALUE>]
6. Run your tests.
7. Stop the instance with the UUID:
gmsaas instances stop <INSTANCE_UUID>
The docs note that gmsaas manages the full lifecycle of the virtual device and uses ADB for the connection. For exact Jenkins examples, use the Jenkins tutorial and the gmsaas CLI reference.