Idea imports an existing web project and publishes it to Tomcat, but finds that Tomcat does not publish automatically question: When importing a web project, idea does not treat it as a web, so you need to modify the project structure yourself 1. Import the project Open File->Open... 2. Found that the icon in front of the project web does not have a small dot
3. Configure and run (1) Configure the operating environment Open Run->Edit Configurations... (2). Click the small plus sign in the upper left corner (3). Select local Tomcat and find the directory (4) When you select Deployment, there is nothing. You will see a red exclamation mark below (thinking things are not that simple). Select Add. (5) Select Build Artifacts Emmm... Sure enough, I can't add the currently imported project You can only add Tomcat first (it can't run yet) Solution: 1. Open Project Structure..., or use the shortcut key: Ctrl+Alt+Shift+S Found that there is no SDK, quietly added it (but this is not the problem) 2. Select Modlues and find that this module exists, but we want to remove it now A warning pops up, which roughly means: Remove the only module of the project, it will not be deleted on the hard disk 3. Re-import
Create a new module in the resources, and then follow the next 4. After clicking Finish, you will find that the small icon in front of the web has a small dot, which means that Idea treats it as a web project 5. Continue to open Project Structure..., select Facets, and you will see the project name
If yes, add one 6. Select Artifacts to add the module 7. Continue back to the configuration run, select the Tomcat created previously, and click the "+" below (I later realized that I didn’t need to add it here. Just select Deployment and add Artifects, and it will be automatically added here.) After adding Select Deployment->+->Artifact... After adding 8. Start Tom Cat! ! ! Report an error... After clicking OK, you will jump to Project Structure (if not, you need to open it yourself), and find that Project Compiler output is empty. Create a new out folder under the project and specify this folder Start again! ! ! Dependency not found... After adding, start...normal... At this point, the problem is solved. Summarize The above is what I introduced to you about solving the problem of importing Web projects into Idea and publishing them to Tomcat. I hope it will be helpful to you. If you have any questions, please leave me a message and I will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website! You may also be interested in:
|
<<: MySQL 8.0.12 installation and environment variable configuration tutorial under win10
>>: Vue-Element-Admin integrates its own interface to realize login jump
This article shares the specific code of a simple...
1. Vulnerability Description On May 15, 2019, Mic...
Web Services are concerned with application-to-ap...
[LeetCode] 178.Rank Scores Write a SQL query to r...
Table of contents 1. List interface display examp...
Using the <img> element with the default sr...
The installation and configuration methods of MyS...
OBS studio is cool, but JavaScript is cooler. Now...
Table of contents 1. TypeScript is introduced int...
This article shares the specific code of JavaScri...
In the previous article - The charm of one line o...
This article uses examples to illustrate how to v...
This article example shares the specific code for...
There is a question that has troubled web designe...
1. Download the mysql tar file: https://dev.mysql...