I am trying to complete my automated deployment process see this question for further info and it is close. I can right click on my MVC project in VS2010 and select "Build deployment package" and it successfully builds it, and this will deploy to the remote server. When I run the following command the build fails:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe mvcproject.csproj /T:Package /p:Configuration=Deployment
The error I get is:
MSDEPLOY : error : Object of type 'manifest' and path 'C:\hoh_code\GIT\ai-poker- project\Packages\Deployment\PokerLeague
WebSite\PokerLeagueWebSite.SourceManifest.xml' cannot be created. [C:\hoh_code\GIT\ai-poker-project\Clients\PokerLeague
WebSite\PokerLeagueWebSite.csproj]
MSDEPLOY : error : One or more entries in the manifest 'sitemanifest' are not valid. [C:\hoh_code\GIT\ai-poker-project\
Clients\PokerLeagueWebSite\PokerLeagueWebSite.csproj]
MSDEPLOY : error : An error occurred when reading the IIS Configuration File 'MACHINE/REDIRECTION'. The identity perfor
ming the operation was 'wiggly\Jon'. [C:\hoh_code\GIT\ai-poker-project\Clients\PokerLeagueWebSite\PokerLeagueWebSite.cs
proj]
MSDEPLOY : error : Filename: \\?\C:\Windows\system32\inetsrv\config\redirection.config [C:\hoh_code\GIT\ai-poker-projec
t\Clients\PokerLeagueWebSite\PokerLeagueWebSite.csproj]
MSDEPLOY : error : Cannot read configuration file due to insufficient permissions [C:\hoh_code\GIT\ai-poker-project\Cli
ents\PokerLeagueWebSite\PokerLeagueWebSite.csproj]
I was under the impression that the right click I was doing was the same thing as the msbuild command. I tried setting the output level to detailed but could not see the command that was triggering it correctly, (possibly not seeing the wood for the tree's though).
My question is, what can I do to get the project to build via the command line so I can build it on my CI Server (doesn't have VS2010) so that it can be automatically deployed, and why is VS2010 succeeding when the command line fails?
error : Cannot read configuration file due to insufficient permissions
Run msbuild from an elevated command prompt to avoid this error. Same procedure you used to elevate Visual Studio. Or change the permissions on the build folder so this isn't necessary.