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 9194613
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T21:27:19+00:00 2026-06-17T21:27:19+00:00

In my $TOMCAT_HOME/conf/server.xml I put this near the bottom: … <Context path=/staticdir docBase=/filesystem/path/to/static/dir/> </Host>

  • 0

In my $TOMCAT_HOME/conf/server.xml I put this near the bottom:

...

 <Context path="/staticdir" docBase="/filesystem/path/to/static/dir"/>                                

      </Host>
    </Engine>
  </Service>
</Server>

I’m doing this because I have files on my filesystem that I want tomcat to serve up when you go to localhost:8080/staticdir

But when I start the application in Intellij-IDEA the tomcat log says this:

Using CATALINA_BASE: “C:\Users\me.IntelliJIdea11\system\tomcat\Unnamed_Product_2”

If I go into that directory on my filesystem and look at the conf/server.xml file, it doesn’t have the Context tag I put in there. Why is intellij modifying this and how can I prevent it?

I have a feeling I should have made this change to my $TOMCAT_HOME/conf/context.xml file instead, but I’m having trouble finding examples of how to make this change in there. If someone could show me an example of that, I’d consider it an answer, because I notice that intellij doesn’t modify that file.


I have found a workaround.

enter image description here

But I really don’t like this because when new users try to run the app for the first time, I can’t imagine a way to detect they did this step incorrectly.

Here’s a picture of my tomcat configuration:

enter image description here

  • 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-17T21:27:21+00:00Added an answer on June 17, 2026 at 9:27 pm

    By default IntelliJ IDEA modifies CATALINA_BASE environment so that Tomcat uses adjusted configuration files for deploying applications directly from the artifact output location, however it’s possible to override this behavior and configure everything manually (either by changing the artifact output to go into webapps or by changing the server configuration in the same way IDEA does so that deployment occurs from the standard artifact output).

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

Sidebar

Related Questions

Tomcat documentation says: The locations for Context Descriptors are; $CATALINA_HOME/conf/[enginename]/[hostname]/context.xml $CATALINA_HOME/webapps/[webappname]/META-INF/context.xml On my server,
I have a web application that uses a library which resides in TOMCAT_HOME/common/lib. This
This is just for my own confirmation really. Is the <CATALINA_HOME>/conf folder in Tomcat
I have put my project in tomcat_home/webapps/ directory. The structure is : project_name/WEB-INF/classes. in
I deploy a application to tomcat with context xml. I want the tomcat work
As siren documentation explains, the file located in tomcat/conf/Catalina/localhost must set the path of
Tomcat 5.5.x and 6.0.x Grails 1.6.x Java 1.6.x OS CentOS 5.x (64bit) VPS Server
When Tomcat starts I get this messages: INFO: Initializing Spring FrameworkServlet 'spring' 2012-06-20 17:02:55,209
Running Solr on Tomcat 7 on Win 2008 Server. I am looping through a
I downloaded apache-tomcat-6.0.35 & put it in tomcat folder. I did accroding to to

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.