服务器启动后如何使用批处理文件启动应用程序? [英] How to launch application after server startup using batch file?

查看:274
本文介绍了服务器启动后如何使用批处理文件启动应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

@echo off
set START_SERVER="C:\Program Files\Apache\Tomcat_6\bin\startup.bat"
call %START_SERVER%
start http://localhost:8080/MyProject/

  • 服务器开始使用批处理后如何在浏览器中启动应用程序?

    • How to launch app in browser after server start using batch?

      我上面的脚本正在启动服务器并启动应用程序..,但两者同时工作.

      My above script is starting server and launching app.. but both working simultaneously.

      推荐答案

      您的代码正确. startup.bat完成后,start将运行. 问题可能在startup.bat中,可能是在完全启动该exe文件之前启动了一个exe文件,然后退出了. 您可以编辑startup.bat或在call行和start行之间设置timeout.

      your code is right. The startwill run, when startup.bat is finished. The problem propably is in startup.bat Propably it starts an exe-file, and then exits, before that exefile is fully started. You can edit startup.bat or set an timeoutbetween the callline and the startline.

      这篇关于服务器启动后如何使用批处理文件启动应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆