Skip to content

Instantly share code, notes, and snippets.

@ChaoLiangSuper
Created June 12, 2019 01:18
Show Gist options
  • Save ChaoLiangSuper/0828c4a9bb944ad7c4fd31b7aa512849 to your computer and use it in GitHub Desktop.
Save ChaoLiangSuper/0828c4a9bb944ad7c4fd31b7aa512849 to your computer and use it in GitHub Desktop.
const sequelize = new Sequelize(config);
const umzug = new Umzug({
storage: "sequelize",
storageOptions: {
sequelize: sequelize
},
migrations: {
params: [
sequelize.getQueryInterface(),
Sequelize
],
path: path.join(__dirname, "./migrations")
}
});
return umzug.up();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment