Dos it exist a way to propagate java system property from Tomcat to jenkins ant task?
Particularly I would like to propagate catalina.home
property to ant task. When trying catalina.home=${catalina.home}
I get error Property catalina.home was circularly defined.

- 2,192
- 1
- 20
- 32
-
Have you actually access to the catalina.home variable in Jenkins? If Jenkins knows it, you can pass it on, otherwise there is no issue. – Peter Schuetze Oct 11 '13 at 17:32
-
I can see catalina.home, if I display System Properties for Jenkins – agad Oct 14 '13 at 06:02
2 Answers
so you want catalina.home
of the tomcat that's running jenkins passed into your ant build?
hmmm... I'm not sure it's goign to work, but try setting the catalina.home
property to the value of the CATALINA_HOME
environment variable:
catalina.home=${evn.CATALINA_HOME}
It likely won't work, you'll want to see what you set CATALINA_HOME
environment variable is and just pass that into your ant build:
ant -Dcatalina.home="/usr/share/tomcat7

- 7,668
- 1
- 36
- 61
-
`CATALINA_HOME` is not set, only system properties `catalina.home` and `catalina.base` are set. – agad Oct 11 '13 at 06:00
I don't think you have direct access from your job configuration to your system properties. You will need to write your own plugin to read out the system properties.
Check if you have CATALINA_HOME available. If you do, pass it into ant (ant plugin has a field for that) or set it within your ant-script like thekbb suggested. catalina.home=${evn.CATALINA_HOME}

- 16,185
- 4
- 44
- 58