2016-02-13 37 views
1

期间停止部署目录我有一个项目结构,看起来大致是这样的MsDeploy CopyAllFilesToSingleFolderForMsdeploy

Root 
    MyProject.Web 
    App 
     js 
     sass 
     img 
     other stuff.. 
    other stuff... 
    other stuff... 

出于某种原因,msdeploy突然停止复制了我的sass目录。有些事情我知道从经验来检查:

  • 包括在的csproj。这是通过App目录<Content Include="App\**\*" />上的通配符完成的。我在几个项目中使用过这个,事实上它以前在这个项目上工作。
  • 在webdeploy的CollectFilesFromContent步骤中列出。

虽然它是在CopyAllFilesToSingleFolderForMsdeploy一步省略

我从CI通过指向MsBuildMyProject.Web.csproj以下参数

/p:DeployTarget=MSDeployPublish /p:Configuration=QA /p:MsDeployServiceUrl="https://${bamboo.deployServer}:8172/MsDeploy.axd";DeployIisAppPath="${bamboo.deploySite}";username="${bamboo.deployUser}";password="${bamboo.deployPassword}" /p:SolutionDir=${bamboo.build.working.directory}\ /p:DeployOnBuild=True /p:MSDeployPublishMethod=WMSVC /p:AllowUntrustedCertificate=True /p:AllowUnsafeBlocks=true 

此推出,这是我的日志截断副本应该证明我在说什么

build 12-Feb-2016 18:57:04 CollectFilesFromContent: 
build 12-Feb-2016 18:57:04  Gather all files from Project items @(Content). Adding: 
build 12-Feb-2016 18:57:04  
App\img\loading.gif; 
<...snip...> 
App\js\app.js; 
App\js\directives\adminNavigation.js; 
<...snip...> 
App\js\screens\myTime\listView.html; 
<...snip...> 
App\sass\admin.css; 
App\sass\admin.scss; 
App\sass\home.css; 
App\sass\home.scss; 
App\sass\lib\_normalize.scss; 
App\sass\login.css; 
App\sass\login.scss; 
<...snip...> 
build 12-Feb-2016 18:57:04 CollectFilesFromIntermediateSatelliteAssembliesWithTargetPath: 
build 12-Feb-2016 18:57:04  Gather all files from Project output (IntermediateSatelliteAssembliesWithTargetPath). Adding: 
build 12-Feb-2016 18:57:04 CollectFilesFromReference: 
build 12-Feb-2016 18:57:04  Gather all files from Project items @(ReferenceCopyLocalPaths,ReferenceComWrappersToCopyLocal,ResolvedIsolatedComModules,_DeploymentLooseManifestFile,NativeReferenceFile). 
build 12-Feb-2016 18:57:04 CollectFilesFromAllExtraReferenceFiles: 
build 12-Feb-2016 18:57:04  Gather all files from Project items @(AllExtraReferenceFiles). Adding: 
build 12-Feb-2016 18:57:04 CollectFilesFrom_SourceItemsToCopyToOutputDirectory: 
build 12-Feb-2016 18:57:04  Gather all files from Project items @(_SourceItemsToCopyToOutputDirectoryAlways,_SourceItemsToCopyToOutputDirectory). Adding: 
build 12-Feb-2016 18:57:04  bin\Version.txt 
build 12-Feb-2016 18:57:04 CollectFilesFrom_binDeployableAssemblies: 
build 12-Feb-2016 18:57:04  Gather all files from Project items @(_binDeployableAssemblies). Adding: 
build 12-Feb-2016 18:57:05 PipelineCollectFilesPhase: 
build 12-Feb-2016 18:57:05  Publish Pipeline Collect Files Phase 
build 12-Feb-2016 18:57:05 PreTransformWebConfig: 
build 12-Feb-2016 18:57:05  Found The following for Config tranformation: 
build 12-Feb-2016 18:57:05  Web.config 
build 12-Feb-2016 18:57:05  Creating directory "E:\CI_BUILD_DIRECTORY\obj\QA\TransformWebConfig\transformed\". 
build 12-Feb-2016 18:57:05  Creating directory "E:\CI_BUILD_DIRECTORY\obj\QA\TransformWebConfig\transformed\Views\". 
build 12-Feb-2016 18:57:05  Copying Web.config to obj\QA\TransformWebConfig\original\Web.config. 
build 12-Feb-2016 18:57:05  Copying E:\CI_BUILD_DIRECTORY\Web.QA.config to obj\QA\TransformWebConfig\assist\Web.config. 
build 12-Feb-2016 18:57:05 TransformWebConfigCore: 
<...snip...> 
build 12-Feb-2016 18:57:05  Transformation succeeded 
build 12-Feb-2016 18:57:05 PostTransformWebConfig: 
build 12-Feb-2016 18:57:05  Transformed Web.config using E:\CI_BUILD_DIRECTORY\Web.QA.config into obj\QA\TransformWebConfig\transformed\Web.config. 
build 12-Feb-2016 18:57:05 PipelineTransformPhase: 
build 12-Feb-2016 18:57:05  Publish Pipeline Transform Phase 
build 12-Feb-2016 18:57:05 PreAutoParameterizationWebConfigConnectionStrings: 
build 12-Feb-2016 18:57:05  Creating directory "E:\CI_BUILD_DIRECTORY\obj\QA\CSAutoParameterize\transformed\Views\". 
build 12-Feb-2016 18:57:05  Copying Views\Web.config to obj\QA\CSAutoParameterize\original\Views\Web.config. 
build 12-Feb-2016 18:57:05  Copying obj\QA\TransformWebConfig\transformed\Web.config to obj\QA\CSAutoParameterize\original\Web.config. 
build 12-Feb-2016 18:57:05 AutoParameterizationWebConfigConnectionStringsCore: 
build 12-Feb-2016 18:57:05  Transforming Source File: E:\CI_BUILD_DIRECTORY\Views\Web.config 
<...snip...> 
build 12-Feb-2016 18:57:05  Transformation succeeded 
build 12-Feb-2016 18:57:05  Transforming Source File: E:\CI_BUILD_DIRECTORY\obj\QA\TransformWebConfig\transformed\Web.config 
build 12-Feb-2016 18:57:05  Applying Transform File: <?xml version="1.0"?> 
<...snip...> 
build 12-Feb-2016 18:57:05  Transformation succeeded 
build 12-Feb-2016 18:57:05 PostAutoParameterizationWebConfigConnectionStrings: 
build 12-Feb-2016 18:57:05  Auto ConnectionString Transformed Views\Web.config into obj\QA\CSAutoParameterize\transformed\Views\Web.config. 
build 12-Feb-2016 18:57:05  Auto ConnectionString Transformed obj\QA\TransformWebConfig\transformed\Web.config into obj\QA\CSAutoParameterize\transformed\Web.config. 
build 12-Feb-2016 18:57:05 PipelineMsdeploySpecificTransformPhase: 
build 12-Feb-2016 18:57:05  Publish Pipeline Deploy phase Stage PipelineMsdeploySpecificTransformPhase 
build 12-Feb-2016 18:57:05 CopyAllFilesToSingleFolderForMsdeploy: 
build 12-Feb-2016 18:57:05  Creating directory "obj\QA\Package\PackageTmp". 
build 12-Feb-2016 18:57:05  Copying all files to temporary location below for package/publish: 
build 12-Feb-2016 18:57:05  obj\QA\Package\PackageTmp. 
build 12-Feb-2016 18:57:05  Copying bin\MyProject.Web.dll to obj\QA\Package\PackageTmp\bin\MyProject.Web.dll. 
build 12-Feb-2016 18:57:05  Copying bin\MyProject.Web.pdb to obj\QA\Package\PackageTmp\bin\MyProject.Web.pdb. 
build 12-Feb-2016 18:57:05  Copying App\img\loading.gif to obj\QA\Package\PackageTmp\App\img\loading.gif. 
<...snip...> 
build 12-Feb-2016 18:57:05  Copying App\js\app.js to obj\QA\Package\PackageTmp\App\js\app.js. 
build 12-Feb-2016 18:57:05  Copying App\js\directives\adminNavigation.js to obj\QA\Package\PackageTmp\App\js\directives\adminNavigation.js. 
<...snip...> 
build 12-Feb-2016 18:57:05  Copying App\js\screens\myTime\listView.html to obj\QA\Package\PackageTmp\App\js\screens\myTime\listView.html. 
<...other files BUT NOT the sass directory...> 

因此, s目录被收集起来进行部署,但实际上并未部署。我对如何进一步调试这个问题感到茫然!

+1

您确定这些文件已更改? MSDeploy默认情况下仅部署已更改的文件。您也可以尝试在本地部署或部署到不同的目标,以查看是否发生相同的问题。 – chief7

+0

@ chief7它实际上删除他们的源代码,但这是一个奇妙的想法。本地部署也不会部署这些文件!我不知道这意味着什么,但是这大大缩短了我的反馈循环 –

回答

0

经过一天的随机猜测我发现这个问题似乎是由于某种原因是实际的目录名称sass。将目录重命名为css解决了问题!

这显然是疯了。除非msdeploy在其中有一个硬编码的文件夹列表,我无法想象这是如何工作的。如果有人有任何细节,请发表一个答案,我会接受它。