Revision #4 has been created by darioo on Oct 3, 2015, 12:29:20 PM with the memo:
« previous (#3)
Execute migration on server/linux using shell
But since you cannot confirm or reject because you are executing php file you put "yes" before that command and it knows that after executing main command it has to confirm. You can put "no" instead.
Before executing file on your server, do it locally on your laptop using XAMPP to test it and see output.
This is working
exec('yes | php yii migrate/up --migrationPath=@vendor/dektrium/yii2-user/migrations')
but I guess this would work also, I didn't test
exec('php yii migrate/up --migrationPath=@vendor/dektrium/yii2-user/migrations | yes')