I'm using vagrant to host my DB and website, but I make changes to my project locally and push changes to the vagrant site. I can run migrate.exe
to update the DB but I can't figure out how to run add-migration
? If I run it locally, it says I have pending changes because I have no DB locally? Can anyone point me in the right direction?
One option to update database without use dotnet ef database update
is execute the command bellow in some default action or startup routine
_dbContext.Database.Migrate();