简体   繁体   中英

Deploying webapp in Tomcat6

I have the following problem. When I developed my application locally I was deploying it using Netbeans support. Now I need to deploy the application on the official server. I installed Tomcat6 and it displays the start page properly but how to deploy my app? Which changes are needed to make ot work on port 80 (at the moment it works on default 8080)? Where should I copy the files from my application? Thanks a lot for helping me out. Links to similar posts are also appreciated. I could not find any that would help me tough.

how to deploy my app

Netbeans on build operation creates a war file in dist folder. See a question about it here. You will need to take this war file and:

Where should I copy the files from my application?

put it under webapp folder in tomcat. The location is your tomcat_home folder->webapps.

Which changes are needed to make to work on port 80

under your tomcat_home folder, open conf folder. Inside, find server.xml file. open it with notepad and change the port number from 8080 to 80:

<Connector port="8080" … />

should be:

<Connector port="80" … />

Don't forget to restart the server!

Now the link to your application will be: http://localhost/YourWarFileName/ or the computer ip/name instead of localhost.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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