0

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.

agad
  • 2,192
  • 1
  • 20
  • 32

2 Answers2

0

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

thekbb
  • 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
0

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}

Peter Schuetze
  • 16,185
  • 4
  • 44
  • 58