entity framework 4 - Teamcity build fails because of EF code migrations -
my teamcity build fails because have project has 2 ef code migration configurations in it.
from build log:
[12:39:58]checking changes [12:39:58]collecting changes in 1 vcs root (1s) [12:40:00]clearing temporary directory: c:\teamcity\buildagent2\temp\buildtmp [12:40:00]publishing internal artifacts [12:40:00]checkout directory: c:\teamcity\buildagent2\work\1679b8b30e00ad0 [12:40:00]updating sources: server side checkout (2s) [12:40:03]step 1/8: gulp (command line) [12:40:03]step 2/8: nuget package refresh (nuget installer) (3s) [12:40:06]step 3/8: compile (msbuild) (21s) [12:40:27]step 4/8: unit tests (nunit) (33s) [12:41:01]step 5/8: transform files (powershell) (2s) [12:41:03]step 6/8: deployment build on xxxxx live (msbuild) (25s) [12:41:29]step 7/8: deploy database (powershell) (5s) [12:41:34]step 8/8: deploy portal.hub (powershell) (33s) [12:42:08]publishing artifacts [12:42:08][publishing artifacts] collecting files publish: [c:\teamcity\buildagent2\temp\buildtmp\nuget5954880593924726328packages\nuget.xml => .teamcity/nuget] [12:42:08][publishing artifacts] publishing using [webpublisher] [12:42:08][publishing artifacts] publishing using [artifactscachepublisher] [12:42:08][publishing artifacts] artifacts path 'c:/teamcity/buildagent2/temp/buildtmp/nuget5954880593924726328packages/nuget.xml' not found [12:42:08]reverting patched assembly versions [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.api\properties\assemblyinfo.cs [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.common\properties\assemblyinfo.cs [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.data\properties\assemblyinfo.cs [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.hub\properties\assemblyinfo.cs [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.manager\properties\assemblyinfo.cs [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.managers\properties\assemblyinfo.cs [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.signalr\properties\assemblyinfo.cs [12:42:08][reverting patched assembly versions] restoring c:\teamcity\buildagent2\work\1679b8b30e00ad0\src\portal.tests\properties\assemblyinfo.cs [12:42:08]publishing internal artifacts [12:42:08][publishing internal artifacts] sending using webpublisher [12:42:08][publishing internal artifacts] sending using artifactscachepublisher [12:42:08]build failure condition: there error reported in 1 of build steps. [12:42:08]build failure condition cause message: error: more 1 migrations configuration type found in assembly 'portal.data'. specify name of 1 use. (show original message) [12:42:08]build finished
note: red (failures) last 2 lines above "build finished"
i not running migrations , can't see steps in team city or publish profile attempting this.
i not want split configurations separate projects, want stop teamcity attempting run them.
my build steps are:
1/8 gulp - minimize js files
2/8 nuget installer - update nuget references in solution
3/8 msbuild - .net 4.5 x86 compile
4/8 nunit - run unit tests
5/8 powershell - run script manipulate app.config files windows service
6/8 msbuild - use publish profile deploy website
7/8 powershell - script deploy database
8/8 powershell - script deploy windows service
the publish profile: validation connection button works ok on connection tab, on settings page there several databases listed none have connection strings or "use connection string @ runtime" checked. 1 of them has info label next "in order publish code first model, code first migrations should used".
we have virtually identical build configurations other projects work fine.
thanks
from logs, appear though trying apply ef migrations in step 7 - deploy database step.
this config exception getting thrown.
if goal stop teamcity running them disabling step that.
hope helps
Comments
Post a Comment