2

考虑 envoy 的以下任务:

@task('deploy', ['on' => 'web'])
    cd personal_site
    php artisan down
    git pull origin master
    composer install
    php artisan migrate
    php artisan up
@endtask

php artisan migrate // Blows up

错误是:

[user@xxxx]: **************************************
*     Application In Production!     *
**************************************
[user@xxxx]: Command Cancelled!
[user@xxxx]: Application is now live.
4

1 回答 1

6

此警告是一种安全措施,可防止在生产环境中运行意外迁移。如果您确定要在该环境中运行它们,则需要使用--force选项:

php artisan migrate --force
于 2016-01-01T21:37:55.227 回答