Aspirerelease/17.0
Watch Aspire live streamsDocsTry Aspire

DistributedApplicationBuilder.AddExecutable

Method
📦 Aspire.Hosting v17.0.0
type DistributedApplicationBuilder interface {
// ... omitted for brevity
AddExecutable(
name string,
command string,
workingDirectory string,
args []string,
) ExecutableResource
}

Signature

methodAddExecutablebuilder
Adds an executable resource to the application model.
AddExecutable(
name string,
command string,
workingDirectory string,
args []string,
) ExecutableResource
namestringThe name of the resource.
commandstringThe executable path. This can be a fully qualified path or a executable to run from the shell/command line.
workingDirectorystringThe working directory of the executable.
args[]stringThe arguments to the executable.
ExecutableResource

The resource builder.

Returns a handle; failures surface later via Err().

Defined on

This method is defined on the following type: