ExecutableResourceBuilderExtensions.AddExecutable Method

Definition

Overloads

AddExecutable(IDistributedApplicationBuilder, String, String, String, Object[])

Adds an executable resource to the application model.

AddExecutable(IDistributedApplicationBuilder, String, String, String, String[])

Adds an executable resource to the application model.

AddExecutable(IDistributedApplicationBuilder, String, String, String, Object[])

Source:
ExecutableResourceBuilderExtensions.cs
Source:
ExecutableResourceBuilderExtensions.cs

Adds an executable resource to the application model.

C#
public static Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.ApplicationModel.ExecutableResource> AddExecutable(this Aspire.Hosting.IDistributedApplicationBuilder builder, string name, string command, string workingDirectory, params object[]? args);

Parameters

name
String

The name of the resource.

command
String

The executable path. This can be a fully qualified path or a executable to run from the shell/command line.

workingDirectory
String

The working directory of the executable.

args
Object[]

The arguments to the executable.

Returns

The IResourceBuilder<T>.

Applies to

.NET Aspire 9.1.0 a .NET Aspire 9.0.0
Produkt Verze
.NET Aspire 9.0.0, 9.1.0

AddExecutable(IDistributedApplicationBuilder, String, String, String, String[])

Source:
ExecutableResourceBuilderExtensions.cs
Source:
ExecutableResourceBuilderExtensions.cs
Source:
ExecutableResourceBuilderExtensions.cs

Adds an executable resource to the application model.

C#
public static Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.ApplicationModel.ExecutableResource> AddExecutable(this Aspire.Hosting.IDistributedApplicationBuilder builder, string name, string command, string workingDirectory, params string[]? args);

Parameters

name
String

The name of the resource.

command
String

The executable path. This can be a fully qualified path or a executable to run from the shell/command line.

workingDirectory
String

The working directory of the executable.

args
String[]

The arguments to the executable.

Returns

The IResourceBuilder<T>.

Applies to

.NET Aspire 9.1.0 a další verze
Produkt Verze
.NET Aspire 8.0.0, 9.0.0, 9.1.0