How can I migrate a doctrine DB in Symfony when the project is disabled
So I disabled my site with
symfony project:disable --env=prod
And rsynced my new code to the server.
But now when I run
symfony doctrine:migrate --env=prod
I get a warning that the site is cu开发者_如何学Crrently unavailable.
I clearly don't want to enable the project (yet) as I first want to make it all works. What is the correct way to do this?
You are right. This doesn't work by default. If your production database is available from your development machine you can start the migration on this machine via:
$> php symfony doctrine:migrate --env=prod
Thats what I do in my deployment scripts
I would probably restrict access to your IP address in the index.php, such as when working in the dev environment. Enable the project and then run again.
精彩评论