Aspire.Hosting.MongoDB
Official
📦 Aspire.Hosting.MongoDBv17.0.0Import path
apphost/modules/aspire15Functions
5Types
5 types, 15 functions and 24 members
Handles
Enums
Functions
DistributedApplicationBuilder
method
AddMongoDBbuilderAdds a MongoDB container resource
AddMongoDB(name string, options ...*AddMongoDBOptions) MongoDBServerResourcemethod
AddMongoDBReplicaSetbuilderAdds a MongoDB replica set resource to the application model.
AddMongoDBReplicaSet(name string, options ...*AddMongoDBReplicaSetOptions) MongoDBReplicaSetResourceMongoDBReplicaSetResource
MongoDBServerResource
method
AddDatabasebuilderAdds a MongoDB database to the application model.
AddDatabase(name string, options ...*AddDatabaseOptions) MongoDBDatabaseResourcemethod
WithBindIpAllbuilderConfigures the MongoDB server to bind to and listen on all network interfaces.
WithBindIpAll() MongoDBServerResourcemethod
WithDataBindMountbuilderAdds a bind mount for the data folder to a MongoDB container resource.
WithDataBindMount(source string, options ...*WithDataBindMountOptions) MongoDBServerResourcemethod
WithDataVolumebuilderAdds a named volume for the data folder to a MongoDB container resource.
WithDataVolume(options ...*WithDataVolumeOptions) MongoDBServerResourcemethod
WithInitFilesbuilderCopies init files into a MongoDB container resource.
WithInitFiles(source string) MongoDBServerResourcemethod
WithKeyFilebuilderSets up a keyfile for internal authentication between members of a MongoDB replica set, with the specified
keyValue as the content of the file.WithKeyFile(keyValue ExpressionValue, options ...*WithKeyFileOptions) MongoDBServerResourcemethod
WithMongoExpressbuilderAdds a MongoExpress administration and development platform for MongoDB to the application model.
WithMongoExpress(options ...*WithMongoExpressOptions) MongoDBServerResourcemethod
WithReplbuilderAdds a REPL command that opens an authenticated MongoDB shell in the dashboard terminal dock.
WithRepl() MongoDBServerResourcemethod
WithReplicaSetbuilderConfigures and initializes the MongoDB server as a single-member replica set for local development.
WithReplicaSet(options ...*WithReplicaSetOptions) MongoDBServerResourcemethod
WithTlsAllowInvalidCertificatesbuilderConfigures the MongoDB server to accept TLS connections whose peer certificate cannot be validated, by passing
--tlsAllowInvalidCertificates to mongod.WithTlsAllowInvalidCertificates() MongoDBServerResourcemethod
WithTlsModebuilderConfigures the
--tlsMode the MongoDB server is started with when TLS is active.WithTlsMode(options ...*WithTlsModeOptions) MongoDBServerResource