1 import "run-test.cwlex" as run_test
2 import "superuser-tok.cwl" as superuser_tok
5 arvados_api_hosts string[],
6 arvados_cluster_ids string[],
7 superuser_tokens string[],
8 arvbox_containers string[],
9 fed_migrate="arv-federation-migrate",
14 logincluster = run expr (arvados_cluster_ids) string (inputs.arvados_cluster_ids[0])
16 scatter arvbox_containers as container,
17 arvados_cluster_ids as cluster_id,
18 arvados_api_hosts as host
19 do run workflow(logincluster, arvbox_bin, refspec)
21 run tool(container, host, arvbox_bin, refspec) {
24 export ARVBOX_CONTAINER="$(inputs.container)"
25 $(inputs.arvbox_bin.path) pipe <<EOF
28 git checkout -f $(inputs.refspec)
30 chown arvbox:arvbox -R .
33 $(inputs.arvbox_bin.path) hotreset
35 while ! curl --fail --insecure --silent https://$(inputs.host)/discovery/v1/apis/arvados/v1/rest >/dev/null ; do sleep 3 ; done
37 ARVADOS_VIRTUAL_MACHINE_UUID=\$($(inputs.arvbox_bin.path) cat /var/lib/arvados-arvbox/vm-uuid)
38 ARVADOS_API_TOKEN=\$($(inputs.arvbox_bin.path) cat /var/lib/arvados-arvbox/superuser_token)
39 while ! curl --fail --insecure --silent -H "Authorization: Bearer $ARVADOS_API_TOKEN" https://$(inputs.host)/arvados/v1/virtual_machines/$ARVADOS_VIRTUAL_MACHINE_UUID >/dev/null ; do sleep 3 ; done
44 supertok = superuser_tok(container, d)
48 report = run_test(arvados_api_hosts, superuser_tokens=supertok, fed_migrate)
49 return supertok, report