Skip to content
Docs Try Aspire
Docs Try

withDataVolume

Method
📦 Aspire.Hosting.MongoDB v13.3.0
interface MongoDBServerResource {
// ... omitted for brevity
withDataVolume(
name?: string,
isReadOnly?: boolean): MongoDBServerResource;
}

Signature

method withDataVolume builder
Adds a named volume for the MongoDB data folder
withDataVolume(
name?: string,
isReadOnly?: boolean): MongoDBServerResource
name string optional
isReadOnly boolean optional = False
MongoDBServerResource

Applies to

This method applies to the following types: