Repository navigation
Conversation
…runner-farm - ./zebrunner.sh doctor checks the host, the settings, the deployment, the network to the MCloud server (the NAT hairpin of STF_PROVIDER_HOST, AGENT_HOSTS of stf-proxy) and the devices, and tells what to fix - the setup ends with the numbered next steps, curve-key prints the STF_ZMQ_CURVE_CLIENT_KEY_<HOST> line of mcloud - ansible offers to remove the running containers of the devices before the deploy - zebrunner-farm: several devices, groups and patterns, -x to exclude, the list and the question in a terminal (filter, exclude, run, cancel), -q; one line per container: running, started, created or the error Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…s of the devices - zebrunner-farm restart --batch (default: all the containers removed, then created) or --rolling (device by device), s of the question switches it - REMOTE_CONNECT_HOST goes to the STF containers (adb connect through the adb relay of mcloud), doctor checks the relay on the ports of the devices and prints the ADB_RELAY_HOSTS entry of the host - proxy_port and server_proxy_port of the devices are dropped: not in mcloud-devices.txt, not passed to appium; doctor reads the list of the earlier format too Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…db relay The relay forwards min_port + 1 of every Android device only: min_port is the screen, it has no login of its own. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…d device - connect_port of a device (optional, Android): STF_PROVIDER_CONNECT_PORT of its STF container (zebrunner/stf fixed connect port), published when it is out of min_port-max_port, validated with the other host ports; appium gets it as ADB_PORT - adb_port is no longer obligatory: unused on Linux, the host port of a USB Android device on macOS - mcloud-devices.txt: connect_port is the 15th field - doctor: the remote debug ports from connect_port (min_port + 1 without it), ADB_RELAY=true of mcloud as the fix Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- ./zebrunner.sh join reads the join string of ./zebrunner.sh node-invite of mcloud (hidden prompt or stdin, never argv), sends the public CURVE key over HTTPS to the pinned TLS key only (curl --pinnedpubkey, the secrets on stdin), validates the answer and writes the settings (mode 600, a private backup): MCLOUD_NODE_TOKEN, the CURVE key of the server, the endpoints, STF_PROVIDER_HOST; the shared tokens are emptied - MCLOUD_NODE_TOKEN replaces NODE_REGISTRATION_TOKEN (appium) and STF_STORAGE_TOKEN (stf) and goes to STF as STF_NODE_TOKEN (the proof of the devices); the prechecks accept it instead of the shared tokens - zebrunner-farm (the secrets of the settings) is deployed readable by root and the user only (750 / 700) - doctor: the enrollment, the shared tokens left, the settings and zebrunner-farm readable by other users - setup: the enrollment is the next step, the manual settings the alternative Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of the node enrollment (design: per-node credentials, self-enrollment with an admin-issued one-time invite, revocation per node). Builds on #459 (included in this branch, merge it first).
./zebrunner.sh join: the join string of./zebrunner.sh node-inviteof mcloud is read from a hidden prompt or stdin (never argv); POST /api/v1/nodes/enroll over HTTPS trusting only the pinned TLS key (curl --pinnedpubkey, body on stdin), the answer is validated (no injection into the settings), the settings are written with mode 600 and a private backup; the sharedNODE_REGISTRATION_TOKEN/STF_STORAGE_TOKENare emptied.MCLOUD_NODE_TOKENreplaces the shared tokens in the containers and goes to STF asSTF_NODE_TOKEN(the HMAC proof binding the devices to the node); prechecks accept it.zebrunner-farmdeployed 750 root: (Linux) / 700 user (macOS): it contains secrets.Related: zebrunner/stf (registry, API, ZAP, storage, device binding), zebrunner/mcloud-grid#216, zebrunner/mcloud#278.
Tests:
make lint,make test(macOS, incl. bash 3.2),make docker(Linux).