@webtypen/webframez-dbdriver-mongodb
v0.0.9
Published
Adds mongodb support/driver to an webtypen-webframez application
Readme
webframez MongoDB Driver
Registration:
app.ts:
import { WebApplication } from "@webtypen/webframez-core";
import { DBDrivers } from "@webtypen/webframez-core/src/Database/DBDriver";
import { MongoDBDriver } from "@webtypen/webframez-dbdriver-mongodb";
// ...
DBDrivers.register("mongodb", MongoDBDriver);
// ...
const app = new WebApplication();
app.boot();Backups
The driver implements the Webframez backup(client, options) hook by running mongodump.
Server requirements:
mongodump --versionOn Ubuntu, install it through MongoDB Database Tools if it is missing.
Example Webframez backup source:
databases: [
{
connection: "default",
to: "database/mongodb",
options: {
gzip: true
}
}
]