mirror of
https://github.com/izzy2lost/docker-android.git
synced 2026-06-19 01:16:28 -07:00
add optional option for device name in json file and use random name instead (Genymotion)
This commit is contained in:
+9
-2
@@ -23,8 +23,15 @@ function prepare_geny_cloud() {
|
||||
device=$(get_value '.device')
|
||||
port=$(get_value '.port')
|
||||
|
||||
echo "Starting \"$device\" with template name \"$template\"..."
|
||||
instance_uuid=$(gmsaas instances start "${template}" "${device}")
|
||||
if [[ $device != null ]]; then
|
||||
echo "Starting \"$device\" with template name \"$template\"..."
|
||||
instance_uuid=$(gmsaas instances start "${template}" "${device}")
|
||||
else
|
||||
echo "Starting Device with Random name..."
|
||||
random_device_name=$(python3 -c 'import uuid; print(str(uuid.uuid4()).upper())')
|
||||
instance_uuid=$(gmsaas instances start "${template}" "${random_device_name}")
|
||||
fi
|
||||
|
||||
echo "Instance-ID: \"$instance_uuid\""
|
||||
created_instances+=("${instance_uuid}")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user