The Gradle build runner runs Gradle projects.
To run builds with Gradle, Gradle 0.9-rc-1 or later must be installed on all the agent machines. Alternatively, if you use the Gradle wrapper, you need to have properly configured Gradle Wrapper scripts checked in to your Version Control.
The runner supports all Gradle build configurations, including
Specify Gradle task names separated by spaces. For example,
Gradle build file
A path to the Gradle build file, relative to the working directory. If empty (default), Gradle uses own settings to determine it.
TeamCity can make use of the Gradle
Gradle home path
Specify here the path to the Gradle home directory (the parent of the
Additional Gradle command line parameters
Optionally, specify the space-separated list of command line parameters to be passed to Gradle.
If enabled, TeamCity will look for Gradle Wrapper scripts in the checkout directory, and launch the appropriate script with Gradle tasks and additional command line parameters specified in the fields above. In this case, Gradle specified in Gradle home path and Gradle installed on the agent are ignored.
Selecting the Log debug messages checkbox is equivalent to adding the
Selecting the Print stacktrace checkbox is equivalent to adding the
Select a JDK. This section details the available options. The default is
JDK home path
The option is available when <Custom> is selected above. Use this field to specify the path to your custom JDK used to run the build. If the field is left blank, the path to JDK Home is read either from the
JVM command line parameters
Additional JVM command line parameters allow you to set initial and maximum heap sizes, enable additional logging, select the required bytecode verifier mode, and more.
You can specify both standard (begin with
To specify multiple command line parameters, use space as a separator. For example:
-verbose:gc -Xdiag -Xcomp -Xmx512m -Xms256m
In Gradle builds, TeamCity system properties are different from Java system properties.
Regular Java system properties can be accessed globally. Use the
providers.systemProperty("my.property").get()methods to obtain these properties' values.
TeamCity system properties are written to the Project object when a build initializes. Therefore, TeamCity system properties can be accessed anywhere the
Projectis available (use
project.hasProperty("property.name")to check whether the required property is available).
The recommended way to reference TeamCity system properties is as follows:
or if the system property's name is a legal name identifier (for example,
system.myPropertyName = myPropertyValue):
In this section, you can specify a Docker image which will be used to run the build step.