addJavaAppWithJar

Method
📦 Aspire.Hosting.Java v17.0.0-preview.1.26567.5
interface IDistributedApplicationBuilder {
// ... omitted for brevity
addJavaAppWithJar(
name: string,
appDirectory: string,
jarPath: string,
args: string[]): JavaAppResource;
}

Signature

methodaddJavaAppWithJarbuilder
Adds a Java application that runs a prebuilt JAR with `java -jar`.
addJavaAppWithJar(
name: string,
appDirectory: string,
jarPath: string,
args: string[]): JavaAppResource
namestringThe name of the resource.
appDirectorystringThe application directory. Relative paths are resolved against the AppHost directory.
jarPathstringThe path to the JAR file to execute. Relative paths are resolved against `appDirectory`.
argsstring[]Arguments passed to the Java application after the JAR path.
JavaAppResource

Applies to

This method applies to the following types: