Watch Aspire live streamsDocsTry Aspire

JavaAppResource.withGradleTask

Method
📦 Aspire.Hosting.Java v13.6.5-preview.1.26559.7
interface JavaAppResource {
// ... omitted for brevity
withGradleTask(
task: string,
args: string[]): JavaAppResource;
}

Signature

methodwithGradleTaskbuilder
Launches the Java application through a Gradle task instead of `java`, for example `bootRun`.
withGradleTask(
task: string,
args: string[]): JavaAppResource
taskstringThe Gradle task to execute.
argsstring[]Additional arguments passed to the Gradle wrapper after the task.
JavaAppResource

Defined on

This method is defined on the following type: