简体   繁体   English

.Net核心,Ef7部署到生产

[英].Net core, Ef7 deploy to production

I Have my core2.0 project finally production ready, 我的core2.0专案终于准备就绪,

Bummer, can't deploy it ot Azure without migrations. Bummer,如果没有迁移就无法在Azure上部署它。 (All migrations are in the code). (所有迁移都在代码中)。

database ready (Empty) 数据库准备就绪(空)

Project ready (ok in local with localdb) 项目准备就绪(可以通过localdb在本地使用)

Now, 现在,

How can I applly all migration in production on "publish" in VS2017 of my app ? 如何在我的应用程序的VS2017中的“发布”上应用生产中的所有迁移?

So far my best guess is : Extract dacpac from localdb, manually apply it to Azure, change connection string. 到目前为止,我最好的猜测是:从localdb提取dacpac,将其手动应用于Azure,更改连接字符串。

But I hope where is a better way ! 但我希望哪里有更好的方法!

Edit : 编辑:

Edit2 : Removed useless rant Edit2:删除了无用的咆哮

Now I feel stupid. 现在我觉得很蠢。 With core2 there is no more need to manually encode things like'&' (=&) In new config you can just put it like it is “&blalalala”. 使用core2,就不再需要手动编码'&'(=&)之类的东西了。在新配置中,您可以像“&blalalala”那样放它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM