Reputation: 160
I'm using two connections in sails app: mongodb and postgresql. For mongodb i want to use "alter" strategy, but postgres db must be readonly. Is there any way to achieve this?
Upvotes: 1
Views: 219
Reputation: 3993
You cannot define it at the connection level, but you can override the configuration for the models of your choice.
// in api/models/PosgresModel.js
module.exports = {
migrate: 'safe',
attributes: {
// The attributes definitions
}
}
Upvotes: 4