如何安装tomcat在intellij中使用它。 Ubuntu

问题描述 投票:0回答:1

我想做什么

我尝试在Ubuntu 18.4上安装tomcat。然后,我想用JavaEnterpriseInteliJ UltimateRESTfulWebService中创建简单的WebApplication应用。

Ubuntu安装

我运行了sudo apt-get install tomcat9,安装过程很可疑。

InteliJ配置

但是我不知道在Tomcat Home空框中的InteliJ配置中写什么。我一直都遇到错误'The selected directory is not valid Tomcat home'

enter image description here

可能的解决方案,但我不想手动安装tomcat

可能是由于建议手动安装tomcat? https://www.javahelps.com/2015/03/install-apache-tomcat-on-ubuntu.html

我不想这样安装它,因为稍后对其进行安装将对我来说很困难,并且我的系统会混乱。

Docker安装

我放弃了apt-get解决方案,并使用以下命令在docker中安装了tomcat:sudo docker运行tomcat:9.0

我在InteliJ中打开了Docker选项卡:

Ubuntu 18.4, InteliJ IDEA Ultimate, docker,

我不知道如何通知InteliJ,在Docker容器中称为recursing_haibt是一个雄猫服务器,它将处理简单的HelloWorld应用并在浏览器中将其打开]

enter image description here

我不知道该怎么办。

java docker ubuntu tomcat intellij-idea
1个回答
0
投票

当我遇到这种情况时,我得到了此文档并进行了纠正https://askubuntu.com/questions/968089/how-to-add-tomcat-8-into-intellij-idea

© www.soinside.com 2019 - 2024. All rights reserved.