How to Configure STF Cluster

Precondition:

master machine: #1 Mac OS - with public ip X slave machine: #2 Mac OS - with public ip Y

Preparing machines

Environment

  1. Xcode 8.3+
  2. Android SDK
  3. Java 1.7+
  4. STF - use this instructions to install the stf on mac os https://github.com/openstf/stf

Getting Started On the macos #1

  1. Start rethinkdb
    1. $ rethinkdb --bind all
  2. Start STF
    1. $ stf local --allow-remote --public-ip X --provider X --bind-dev-pub tcp://X:7114 --bind-dev-pull tcp://X:7116

On the macos #2

  1. Start provider
    1. $ stf provider --connect-sub tcp://X:7114 --connect-push tcp://X:7116 --storage-url http://X:7100 --public-ip Y --min-port=35000 --max-port=40000 --heartbeat-interval 20000

Script for autostart STF You can add this sh script using the instructionexport PATH=$PATH:/usr/local/bin;
while true; do 
/Users/user/Library/Android/sdk/platform-tools/adb kill-server; 
/Users/user/Library/Android/sdk/platform-tools/adb start-server; 
/usr/local/bin/rethinkdb -d /Users/user/dev/stf/rethinkdb_data/ --bind all &
pid=$!;
sleep 15; 
/usr/local/bin/stf local --allow-remote --public-ip 192.168.0.124 --provider 192.168.0.124 --bind-dev-pub tcp://192.168.0.124:7114 --bind-dev-pull tcp://192.168.0.124:7116;
kill $pid; 
sleep 10; 
done

Troubleshooting

Installing the stf with error: no member named 'ForceSet' in 'v8::Object'

Check the nodejs version - it should not be version > 9.11.1

Downgrade nodejs if you have version more than 9.11.1