17db96d56Sopenharmony_ci@echo off 27db96d56Sopenharmony_cirem Used by the buildbot "remotedeploy" step. 37db96d56Sopenharmony_cisetlocal 47db96d56Sopenharmony_ci 57db96d56Sopenharmony_ciset PATH=%PATH%;%SystemRoot%\SysNative\OpenSSH;%SystemRoot%\System32\OpenSSH 67db96d56Sopenharmony_ciset here=%~dp0 77db96d56Sopenharmony_ciset arm32_ssh= 87db96d56Sopenharmony_ciset suffix=_d 97db96d56Sopenharmony_ciif "%REMOTE_PYTHON_DIR%"=="" (set REMOTE_PYTHON_DIR=C:\python\) 107db96d56Sopenharmony_ciif NOT "%REMOTE_PYTHON_DIR:~-1,1%"=="\" (set REMOTE_PYTHON_DIR=%REMOTE_PYTHON_DIR%\) 117db96d56Sopenharmony_ci 127db96d56Sopenharmony_ci:CheckOpts 137db96d56Sopenharmony_ciif "%1"=="-arm32" (set arm32_ssh=true) & (set prefix=%REMOTE_PYTHON_DIR%pcbuild\arm32) & shift & goto CheckOpts 147db96d56Sopenharmony_ciif "%1"=="-d" (set suffix=_d) & shift & goto CheckOpts 157db96d56Sopenharmony_ciif "%1"=="+d" (set suffix=) & shift & goto CheckOpts 167db96d56Sopenharmony_ciif NOT "%1"=="" (echo unrecognized option %1) & goto Arm32SshHelp 177db96d56Sopenharmony_ci 187db96d56Sopenharmony_ciif "%arm32_ssh%"=="true" goto :Arm32Ssh 197db96d56Sopenharmony_ci 207db96d56Sopenharmony_ci:Arm32Ssh 217db96d56Sopenharmony_ciif "%SSH_SERVER%"=="" goto :Arm32SshHelp 227db96d56Sopenharmony_ci 237db96d56Sopenharmony_ciset PYTHON_EXE=%prefix%\python%suffix%.exe 247db96d56Sopenharmony_ciecho on 257db96d56Sopenharmony_cissh %SSH_SERVER% %PYTHON_EXE% -m test.pythoninfo 267db96d56Sopenharmony_ciexit /b %ERRORLEVEL% 277db96d56Sopenharmony_ci 287db96d56Sopenharmony_ci:Arm32SshHelp 297db96d56Sopenharmony_ciecho SSH_SERVER environment variable must be set to administrator@[ip address] 307db96d56Sopenharmony_ciecho where [ip address] is the address of a Windows IoT Core ARM32 device. 317db96d56Sopenharmony_ciecho. 327db96d56Sopenharmony_ciecho The test worker should have the SSH agent running. 337db96d56Sopenharmony_ciecho Also a key must be created with ssh-keygen and added to both the buildbot worker machine 347db96d56Sopenharmony_ciecho and the ARM32 worker device: see https://docs.microsoft.com/en-us/windows/iot-core/connect-your-device/ssh 357db96d56Sopenharmony_ciexit /b 127 36