Closed knstvk closed 4 years ago
To QA:
deploy/app_home/logback.xml
is created on setupTomcat
(or start in Studio).deploy/app_home/logs
on all operating systems.$ export CATALINA_OPTS="-Dapp.home=/my_path_to_app_home"
$ cd tomcat/bin
$ ./startup.sh
Problem
Developers get confused with differences in locations of app working directories,
local.app.properties
, log config and logs in development and production environments. So we are going to use app home directory both for development and production environments.Solution
app.home
Java system property pointing to a writable directory is now required. If it is not set from the command line, it is automatically set according to the following rules (and the appropriate message is printed to the console/log):catalina.base
system property is set (i.e. working under Tomcat), app home is set to${catalina.base}/work/app_home
$HOME/.app_home
.In development environment,
deploy/tomcat/bin/setenv.*
scripts defineapp.home
indeploy/app_home
After migration of an existing project to CUBA 7.2, it is necessary to remove
deploy/tomcat
completely. ThensetupTomcat
task will create it with the correctsetenv
scripts.buildWar.appHome
parameter is deprecated and not used anymore. The location of app home must be set via Java system property.Uber JAR works as before:
app.home
Java system property is set automatically to the working dir if not provided on the command line.See also cuba-platform/cuba#2319