RustAppResource

Handle
📦 Aspire.Hosting.Rust v17.0.0-preview.1.26567.5
interface RustAppResource
extends IComputeResource,
IContainerFilesDestinationResource,
IResource,
IResourceWithArgs,
IResourceWithEndpoints,
IResourceWithEnvironment,
IResourceWithProbes,
IResourceWithWaitSupport,
IResourceWithServiceDiscovery {
readonly resourceTypeDisplayName: string;
withCargoArgs(args: string[]): RustAppResource;
withCargoBinTarget(binName: string): RustAppResource;
withCargoExample(exampleName: string): RustAppResource;
withCargoFeatures(features: string[]): RustAppResource;
withCargoLocked(locked?: boolean): RustAppResource;
withCargoManifestPath(manifestPath: string): RustAppResource;
withCargoPackage(packageName: string): RustAppResource;
withCargoProfile(profileName: string): RustAppResource;
withCargoReleaseBuild(releaseBuild?: boolean): RustAppResource;
withCargoTarget(target: string): RustAppResource;
}

Properties

propertyresourceTypeDisplayNamestringget
Gets the ResourceTypeDisplayName property

Methods

methodwithCargoArgsbuilder
Adds command-line arguments to the cargo command used by a Rust application.
withCargoArgs(args: string[]): RustAppResource
argsstring[]The cargo arguments to append before `--`.
RustAppResource
methodwithCargoBinTargetbuilder
Configures the binary target to run for Rust applications that declare more than one.
withCargoBinTarget(binName: string): RustAppResource
binNamestringThe binary target name, as declared by `[[bin]] name` in Cargo.toml.
RustAppResource
methodwithCargoExamplebuilder
Configures an example target to run instead of a binary.
withCargoExample(exampleName: string): RustAppResource
exampleNamestringThe example name, as declared by a file or directory under `examples/`.
RustAppResource
methodwithCargoFeaturesbuilder
Adds cargo features for the Rust application.
withCargoFeatures(features: string[]): RustAppResource
featuresstring[]The features to enable.
RustAppResource
methodwithCargoLockedbuilder
Configures the Rust application to build and run with the exact dependency versions recorded in `Cargo.lock`.
withCargoLocked(locked?: boolean): RustAppResource
lockedbooleanoptional= True`true` to add `--locked`; otherwise `false`.
RustAppResource
Configures the `Cargo.toml` cargo builds from.
withCargoManifestPath(manifestPath: string): RustAppResource
manifestPathstringThe path to the manifest, absolute or relative to the app directory.
RustAppResource
methodwithCargoPackagebuilder
Configures the workspace package to build and run.
withCargoPackage(packageName: string): RustAppResource
packageNamestringThe cargo package name.
RustAppResource
methodwithCargoProfilebuilder
Configures the named cargo profile to build with.
withCargoProfile(profileName: string): RustAppResource
profileNamestringThe profile name, for example `dev`, `release`, or a custom profile.
RustAppResource
Configures the Rust application to run using release optimization.
withCargoReleaseBuild(releaseBuild?: boolean): RustAppResource
releaseBuildbooleanoptional= True`true` to add `--release`; otherwise `false`.
RustAppResource
methodwithCargoTargetbuilder
Configures the target triple cargo builds for.
withCargoTarget(target: string): RustAppResource
targetstringThe target triple, for example `x86_64-unknown-linux-musl`.
RustAppResource