Skip to content
Docs Try Aspire

withDataVolume

Function
📦 Aspire.Hosting.Nats v13.2.0-preview.1.26159.1
interface NatsServerResource {
// ... omitted for brevity
withDataVolume(
name?: string,
isReadOnly?: boolean): NatsServerResource;
}

Signature

method withDataVolume builder
Adds a persistent data volume to the NATS resource.
withDataVolume(
name?: string,
isReadOnly?: boolean): NatsServerResource
name string optional
isReadOnly boolean optional = False
NatsServerResource

Applies to

This function is an extension method on the following types: