migrate sails

イシュー

: Unidling
: State changed from down to starting
: 
: > sails-sb5@0.0.0 start /app
: 
: > node app.js
: Starting process with command `npm start`
: `sails.config.express` is deprecated; use `sails.config.http` instead.
: memory, and will not scale past a single process.
: Warning: connection.session() MemoryStore is not
: designed for a production environment, as it will leak
: Passport Initialize.
:  In short, this setting controls whether/how Sails will attempt to automatically
:  Excuse my interruption, but it looks like this app
:  rebuild the tables/collections/sets/etc. in your database schema.
: -----------------------------------------------------------------
: 
:  does not have a project-wide "migrate" setting configured yet.
:  (perhaps this is the first time you're lifting it with models?)
: What would you like Sails to do?
:  
: 
:  migrate:"safe" to protect inadvertent deletion of your data.
:  1. safe  - never auto-migrate my database(s). I will do it myself (by hand) 
:  2. alter - auto-migrate, but attempt to keep my existing data (experimental)
:  3. drop  - wipe/drop ALL my data and rebuild models every time I lift Sails
:  You can read more about the "migrate" setting here:
: To skip this prompt in the future, set `sails.config.models.migrate`.
:  http://sailsjs.org/#/documentation/concepts/ORM/model-settings.html?q=migrate
: (conventionally, this is done in `config/models.js`)
: 
:  In a production environment (NODE_ENV==="production") Sails always uses
: 
:  However during development, you have a few other options for convenience:
: 
: 
: 
: ** DO NOT CHOOSE "2" or "3" IF YOU ARE WORKING WITH PRODUCTION DATA **
: State changed from starting to crashed
: State changed from crashed to starting
: Process exited with status 0
: 
: > sails-sb5@0.0.0 start /app
: > node app.js
: 
: Starting process with command `npm start`
: `sails.config.express` is deprecated; use `sails.config.http` instead.
: Warning: connection.session() MemoryStore is not
: designed for a production environment, as it will leak
: memory, and will not scale past a single process.
: Passport Initialize.
: -----------------------------------------------------------------
: 
:  Excuse my interruption, but it looks like this app
:  does not have a project-wide "migrate" setting configured yet.
:  (perhaps this is the first time you're lifting it with models?)
:  
:  In short, this setting controls whether/how Sails will attempt to automatically
:  rebuild the tables/collections/sets/etc. in your database schema.
:  You can read more about the "migrate" setting here:
:  http://sailsjs.org/#/documentation/concepts/ORM/model-settings.html?q=migrate
:  2. alter - auto-migrate, but attempt to keep my existing data (experimental)
: 
: 
:  In a production environment (NODE_ENV==="production") Sails always uses
: What would you like Sails to do?
:  migrate:"safe" to protect inadvertent deletion of your data.
: 
:  However during development, you have a few other options for convenience:
: 
: To skip this prompt in the future, set `sails.config.models.migrate`.
: (conventionally, this is done in `config/models.js`)
:  1. safe  - never auto-migrate my database(s). I will do it myself (by hand) 
: 
:  3. drop  - wipe/drop ALL my data and rebuild models every time I lift Sails
: ** DO NOT CHOOSE "2" or "3" IF YOU ARE WORKING WITH PRODUCTION DATA **
: 

migrate に関するドキュメント

参考

safe, drop, alter

  • safe を設定すると何もしない
  • drop を設定すると、起動時に作りなおす
  • alter を設定すると、起動時に alter table を試みる