Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8898503
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T00:37:52+00:00 2026-06-15T00:37:52+00:00

I am trying to launch a localhost application on Ubuntu with Apache and proxy

  • 0

I am trying to launch a localhost application on Ubuntu with Apache and proxy it to Tomcat so that I can use .jsp pages in my application. It seems that this is possible and I think that I am pretty close, but I can’t seem to get it quite right. Any help is greatly appreciated! I’ve never used apache or tomcat before, so please don’t hate me if any of this seems stupid.

I’ve got Apache hosting a site at localhost with this code for the host:

<VirtualHost *:80>
ServerName localhost
ServerAlias test.com

DocumentRoot /var/www/test.com/helloworld
<Directory />
    Options FollowSymLinks
    AllowOverride None
</Directory>
<Directory /var/www/>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order allow,deny
    allow from all
</Directory>

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
    AllowOverride None
    Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
    Order allow,deny
    Allow from all
</Directory>

ErrorLog ${APACHE_LOG_DIR}/error.log

# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn

CustomLog ${APACHE_LOG_DIR}/access.log combined

Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
    Options Indexes MultiViews FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
    Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>

</VirtualHost>

This allows me to successfully navigate to my page hello.html by typing localhost/hello.html in the URL. I have read that from this point, I need to insert some code such as:

ProxyRequests Off
ProxyPreserveHost On

<Proxy *>
  Order deny,allow
  Allow from all
</Proxy>

ProxyPass /(appname) ajp://localhost:8009/(appname)
ProxyPassReverse /(appname) ajp://localhost:8009/(appname)

and then Tomcat should get the requests. In this case, what would the appname be? My page is located at /var/www/test.com/helloworld/hello.html, so I thought it would be “helloworld”, but that does not work. When I leave the appname blank, I see the Tomcat “Congratulations, you’ve successfully installed Tomcat.” when I navigate to localhost, but cannot find my page.

Please help. This is slowly becoming a nightmare. Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T00:37:53+00:00Added an answer on June 15, 2026 at 12:37 am

    I figured it out. This is super dumb, but I was trying to load the application from /var/www rather than housing it within the tomcat directories. /facepalm

    The proxy code I posted in the original question is the only code needed in the virtualhost. Thanks everyone.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to launch an external updater application for a platform that I've developed.
I'm trying to launch an intent from my application that will play audio from
I am trying to launch my hello world application in emulator of android. But
I am trying to launch a XPage(web) mobile application from a email(Lotus traveller). When
I'm trying to launch a server on my tomcat 7 on my eclipse indigo
I'm trying to launch a webview that will play a youtube video full screen
I'm trying to launch another application from C# application, is there a way to
I am trying to use Selenium RC but i keep getting this error whenever
Trying to launch and pass tel. no. to skype by this code from my
I'm trying to launch my ClickOnce application using C# code with HttpWebRequest class. The

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.