Intellij tomcat本地运行配置 – 幕后会发生什么?
我一直在使用tomcat运行配置没有任何问题 – 它做得很好。 然而,我有点不喜欢它没有记录在任何地方(或者是它?)这个魔法实际上是如何发生的。
我想它以某种方式使得目标目录中的工件创建了tomcat引用应用程序(如果使用maven)。 我还注意到,当使用manager-gui应用程序时,没有部署其他应用程序,所以它不能使用tomcat / webapps目录。
我很好奇的是:
- 如何启动tomcat指向tomcat之外的应用程序?
- 它是否使用{project_dir} / target / {appName}部署我的应用程序?
- manager-gui app在哪里?
- 日志和配置文件在哪里?
我正在使用IntelliJ IDEA 15.0.3,Tomcat 8.0.15和JDK 1.8.0_31
这是C:\Program Files (x86)\JetBrains\IntelliJ IDEA 15.0.2\bin\idea.properties
:
#--------------------------------------------------------------------- # Uncomment this option if you want to customize path to IDE system folder. Make sure you're using forward slashes. #--------------------------------------------------------------------- # idea.system.path=${user.home}/.IntelliJIdea/system idea.system.path=D:/dev/IntelliJ-Settings/system
在File
– > Settings...
– > Build, Execution, Deployment
– > Application Servers
我已经定义了这个:(查看Tomcat base directory
)
D:\catalina-base-idea
包含IntelliJ的全局Tomcat配置。
当我使用IntelliJ运行配置部署我的webapp时,Web应用程序将部署到D:\dev\IntelliJ-Settings\system\tomcat
(请参阅idea.properties
)。
以上解释了问题1。
问题2:afaik, target
仅用于构建,而不用于部署。
问题3: D:\dev\IntelliJ-Settings\system\tomcat\webapps
没有管理器应用程序
问题4:日志位于D:\dev\IntelliJ-Settings\system\tomcat\webapps\yourApp
。 全局Tomcat配置位于D:\catalina-base-idea
。
您可以为IntelliJ配置Tomcat,以便它使用8080以外的端口。因此,您可以同时启动标准Tomcat和IntelliJ Tomact。