Environment variable for Tomcat log directory?

Answered

IDEA Ultimate's Tomcat integration is great, but I was wondering if there's an environment variable to point to the (temporary) Tomcat working path, not the Tomcat installation.  I repeatedly need to get to extra log files which are stored in the temporary working directory, which on my system is something like:

 

C:\Users\me\.IntelliJIdea15\system\tomcat\Unnamed_installation_here\logs

 

Where "Unnamed_installation_here" is different for every configuration.    It would be nice to have a variable or property like ${project.logs} to point to.    Is there such a thing? 

6 comments
Comment actions Permalink

Where do you want to use this environment variable?

When Tomcat is started, IDEA passes CATALINA_BASE environment variable to catalina startup script:

If you need to use it later, you can probably adjust catalina script so that it saves this variable value into some file where you can access it.

0
Comment actions Permalink

I'd really like to use it in this dialog.  Maybe there's something I don't understand, but the temporary CATALINA_BASE path seems to change periodically.

 

 

 

0
Comment actions Permalink

It should not change if you don't rename the project or run/debug configuration. This dialog doesn't support environment variables.

0
Comment actions Permalink

Hmm, well that takes care of that idea.   Thanks for the information.

0
Comment actions Permalink

Is there a ticket somewhere for this feature enhancement?  It's kind of a PITA to force our developers to put stuff in the same locations everywhere just so IDEA projects don't break.  Ideally we wouldn't need any absolute paths stored anywhere besides like a single variable or some such.

0
Comment actions Permalink

You can submit a ticket at https://youtrack.jetbrains.com/issues/IDEA and describe the use case.

0

Please sign in to leave a comment.