Share via


MongoDBBuilderExtensions Class

Definition

Provides extension methods for adding MongoDB resources to an IDistributedApplicationBuilder.

public static class MongoDBBuilderExtensions
type MongoDBBuilderExtensions = class
Public Module MongoDBBuilderExtensions
Inheritance
MongoDBBuilderExtensions

Methods

AddDatabase(IResourceBuilder<MongoDBServerResource>, String, String)

Adds a MongoDB database to the application model.

AddMongoDB(IDistributedApplicationBuilder, String, Nullable<Int32>, IResourceBuilder<ParameterResource>, IResourceBuilder<ParameterResource>)

Adds a MongoDB resource to the application model. A container is used for local development.

AddMongoDB(IDistributedApplicationBuilder, String, Nullable<Int32>)

Adds a MongoDB resource to the application model. A container is used for local development.

WithDataBindMount(IResourceBuilder<MongoDBServerResource>, String, Boolean)

Adds a bind mount for the data folder to a MongoDB container resource.

WithDataVolume(IResourceBuilder<MongoDBServerResource>, String, Boolean)

Adds a named volume for the data folder to a MongoDB container resource.

WithHostPort(IResourceBuilder<MongoExpressContainerResource>, Nullable<Int32>)

Configures the host port that the Mongo Express resource is exposed on instead of using randomly assigned port.

WithInitBindMount(IResourceBuilder<MongoDBServerResource>, String, Boolean)

Adds a bind mount for the init folder to a MongoDB container resource.

WithMongoExpress<T>(IResourceBuilder<T>, Action<IResourceBuilder<MongoExpressContainerResource>>, String)

Adds a MongoExpress administration and development platform for MongoDB to the application model.

Applies to