我正在运行一个脚本,它向我询问多个输入,如" R" " Y" " IP地址"。如何使这个自动化。如何通过R然后再次R然后IP地址?我在网上尝试了一些例子,但它不起作用......
1) PS C:\orchestrator\scripts> ./Install-Orchestrator.ps1 echo "Y`r" | pw
2)./Install-Orchestrator.ps1 |echo R
3).powershell.exe -noexit -file 'Install-Orchestrator.ps1' "R"
以下是脚本和选项
PS C:\orchestrator\scripts> ./Install-Orchestrator.ps1
Security warning
Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your
computer. If you trust this script, use the Unblock-File cmdlet to allow the script to run without this warning
message. Do you want to run C:\orchestrator\scripts\Install-Orchestrator.ps1?
[D] Do not run [R] Run once [S] Suspend [?] Help (default is "D"): R
---------------------------------
UiPath Orchestrator v2 Installer
---------------------------------
Security warning
Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your
computer. If you trust this script, use the Unblock-File cmdlet to allow the script to run without this warning
message. Do you want to run C:\orchestrator\scripts\Test-FrameworkVersion.ps1?
[D] Do not run [R] Run once [S] Suspend [?] Help (default is "D"): R
Checking current version of .NET
Current .NET version installed 4.7
You have correct version of .NET: (4.7)
Security warning
Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your
computer. If you trust this script, use the Unblock-File cmdlet to allow the script to run without this warning
message. Do you want to run C:\orchestrator\scripts\Test-WebDeployVersion.ps1?
[D] Do not run [R] Run once [S] Suspend [?] Help (default is "D"): R
Checking current version of Web Deploy
You have correct version of Web Deploy 3.1237.1764
Do you want to test port to database?
[Y] Yes [N] No [?] Help (default is "N"): Y
Testing open port to database
Security warning
Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your
computer. If you trust this script, use the Unblock-File cmdlet to allow the script to run without this warning
message. Do you want to run C:\orchestrator\scripts\Test-PortOpen.ps1?
[D] Do not run [R] Run once [S] Suspend [?] Help (default is "D"): R
Enter the host/ip address: 10.10.10.100
Enter the port number to access: 1433