Answer the question
In order to leave comments, you need to log in
MongoDB migration not working, why?
Downloaded the migration package migrate-mongo
Configuration
const path = require('path');
const dotenv = require('dotenv').config({ path: path.resolve(__dirname, '../.env') })
const config = {
mongodb: {
url: dotenv.parsed.DATABASE_HOST,
databaseName: dotenv.parsed.DB_NAME,
options: {
useNewUrlParser: true,
useUnifiedTopology: true,
}
},
migrationsDir: "migrations",
changelogCollectionName: "changelog",
migrationFileExtension: ".js"
};
module.exports = config;
migrate-mongo up
I get ERROR: Authentication failed.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question