Foros de discusión

Incorrect path to Tomcat in build.properties?

thumbnail
Kravchenko Dmitry, modificado hace 13 años.

Incorrect path to Tomcat in build.properties?

Regular Member Mensajes: 139 Fecha de incorporación: 4/10/10 Mensajes recientes
Trying to execute one Ant target I found an error, which led me to build.properties file. My file contains the following lines at position 71:


#
# Specify the paths to an unzipped Tomcat bundle.
#
app.server.type=tomcat
app.server.dir=${project.dir}/../bundles/tomcat-6.0.26
app.server.deploy.dir=${app.server.dir}/webapps
app.server.lib.global.dir=${app.server.dir}/lib/ext
app.server.portal.dir=${app.server.dir}/webapps/ROOT

Note the "bundles" directory here: I have none in this place.

I have Tomcat in separate place.

What do I need to do to either have it in SDK expected place or to have SDK be configured to know Tomcat's correct place?
thumbnail
jelmer kuperus, modificado hace 13 años.

RE: Incorrect path to Tomcat in build.properties?

Liferay Legend Mensajes: 1191 Fecha de incorporación: 10/03/10 Mensajes recientes
You download and unzip tomcat somewhere then in the root of the sdk you create a file called

build.YOURUSERNAME.properties to which you add

app.server.dir=<PATH TO YOUR TOMCAT INSTALL>
thumbnail
Hitoshi Ozawa, modificado hace 13 años.

RE: Incorrect path to Tomcat in build.properties?

Liferay Legend Mensajes: 7942 Fecha de incorporación: 24/03/10 Mensajes recientes
## To update the properties of this file, create a separate properties file
## named "build.${user.name}.properties" with the properties to overwrite.

Create there files:
build.YOURUSERNAME.properties
app.server.YOURUSERNAME.properties
thumbnail
Kravchenko Dmitry, modificado hace 13 años.

RE: Incorrect path to Tomcat in build.properties?

Regular Member Mensajes: 139 Fecha de incorporación: 4/10/10 Mensajes recientes
But what if I need not to refer my user name? I have tomcat installed in system-wide place. Why should I refer it with user-wide properties?
thumbnail
Kravchenko Dmitry, modificado hace 13 años.

RE: Incorrect path to Tomcat in build.properties?

Regular Member Mensajes: 139 Fecha de incorporación: 4/10/10 Mensajes recientes
In other words: where did the default setting came from at all? Who was expecting that Tomcat will be located in bundles subdirectory? Why?
thumbnail
Minhchau Dang, modificado hace 13 años.

RE: Incorrect path to Tomcat in build.properties?

Liferay Master Mensajes: 598 Fecha de incorporación: 22/10/07 Mensajes recientes
Kravchenko Dmitry:
In other words: where did the default setting came from at all? Who was expecting that Tomcat will be located in bundles subdirectory? Why?

It's coded into build.properties. Because that file can change between releases of the plugins SDK, it is (usually) recommended that you override values in a separate file.

If username does not work, then in some cases, you can use pretty much any of the files listed at the top of build-common.xml where "env.VARIABLENAME" corresponds to some environment variable, keeping in mind that due to Ant using immutable properties, the ones that appear first in the list take precedence.
thumbnail
Kravchenko Dmitry, modificado hace 13 años.

RE: Incorrect path to Tomcat in build.properties?

Regular Member Mensajes: 139 Fecha de incorporación: 4/10/10 Mensajes recientes
I found in code, that I can use machine name instead of user name in the override file. Using a machine name seems more reasonably for me.

Thanks emoticon
Miguel Pereira, modificado hace 10 años.

RE: Incorrect path to Tomcat in build.properties?

New Member Mensajes: 4 Fecha de incorporación: 14/01/14 Mensajes recientes
How do I tell ant to use the build.<username>.properties file for deployment?
ant deploy doesn't seem to pick them up...

Thanks emoticon
Miguel Pereira, modificado hace 10 años.

RE: Incorrect path to Tomcat in build.properties?

New Member Mensajes: 4 Fecha de incorporación: 14/01/14 Mensajes recientes
Oh figured it out.. was using app.server.dir instead of app.server.parent.dir emoticon tks