Hi,
I have installed both apache2 and tomcat7 on my ubuntu14.04 droplet. Apache is running on default port 80 and tomcat7 on 8080. I have an application deployed on tomcat and to access it, the url looks like: www.mysite.com:8080/Application_name/
But i want my application to come up when user just enters www.mysite.com
How to configure this?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Thank you for helping . I have a problem When I follow your steps, bd does not work Please help me
As you are already running Apache, the easiest way to do this would be to set it up as a reverse proxy in front of Tomcat.
First, make sure mod_proxy is enabled by running:
sudo a2enmod proxy
sudo a2enmod proxy_http
service apache2 restart
Then create a new virtual host in a file named /etc/apache2/sites-available/tomcat.conf In it, you can configure it to point your domain to your Tomcat app:
<VirtualHost *:80>
ServerName www.mysite.com
ProxyRequests On
ProxyPass / http://localhost:8080/Application_name/
ProxyPassReverse / http://localhost:8080/Application_name/
</VirtualHost>
Note that the ServerName directive is important. Make sure that the virtual host for what Apache is already serving on port 80 also has ServerName set so that Apache can route the requests correctly.
Finally, enable the site and reload Apache:
sudo a2ensite tomcat
sudo service apache2 reload
Now visiting www.mysite.com should display the Tomcat application.
Como es eso de crear una maquina virtual , me podrian explicar por favor :( … Gracias
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.