简体   繁体   English

为什么在 windows vm 上通过 ssh 打开 jar 文件以隐身方式打开浏览器?

[英]Why opening a jar file thru ssh on a windows vm opens the browser incognito?

If I open manually (java -jar name.jar)it works.如果我手动打开(java -jar name.jar)它可以工作。 When I try to open it with ssh command it opens the browser incognito.当我尝试使用 ssh 命令打开它时,它会隐身打开浏览器。 I have a windows vm with windows server.我有一个带有 windows 服务器的 windows 虚拟机。 JDK is installed. JDK 已安装。

I can imagine you have proper installation (your question details was little bit ambiguous) but in any case it could be the java command is not on the command search path for your user account and take this steps to make sure about installation我可以想象你有正确的安装(你的问题细节有点模棱两可),但无论如何它可能是 java 命令不在你的用户帐户的命令搜索路径上,并采取这些步骤来确保安装

  • verify that Java is installed java -version验证 Java 已安装java -version
  • Confirm the PATH variable includes Java's \bin directory in your remote machine确认 PATH 变量包含远程计算机中的 Java 的 \bin 目录

After verification create shell file and execute shell as ssh user@host "sh ~/app-runner.sh" , you may also see here to how create shell for executing jar file(s). After verification create shell file and execute shell as ssh user@host "sh ~/app-runner.sh" , you may also see here to how create shell for executing jar file(s).

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM