git - Visual Studio Team Services 代码未与 Azure 网站同步 - git

标签 git azure azure-devops

该代码肯定会推送到 Visual Studio Online。在那。检查 Kudu,内容正在写入部署和锁定文件夹,但代码未与存储库同步。尽管更新了时间戳,锁文件夹还是空的(不确定这是否重要)。在部署文件夹中,“事件”文件已更新并包含如下值:3c80c6c4bc336c9799549385d8c35ba6b8e4cc45,这是包含有关代码的先前版本的信息的文件夹的名称。这里也有一堆“temp”文件夹,深入到 status.xml 文件中代表最新代码推送的文件夹:

<deployment>
  <id>temp-1fcaf088</id>
  <author>VSTS</author>
  <deployer>VSTS</deployer>
  <authorEmail>VSTS</authorEmail>
  <message>Synchronizing changes from VSTS ...</message>
  <progress/>
  <status>Failed</status>
  <statusText/>
  <lastSuccessEndTime/>
  <receivedTime>2017-03-01T07:55:13.8296373Z</receivedTime>
  <startTime>2017-03-01T07:55:13.8296373Z</startTime>
  <endTime>2017-03-01T07:55:18.3705755Z</endTime>
  <complete>True</complete>
  <is_temp>True</is_temp>
  <is_readonly>False</is_readonly>
</deployment>

并在 log.log 文件中:

2017-03-01T07:55:13.9077727Z,Fetching changes.,6d1544dd-5cd5-44b2-a218-93578363eb66,0
2017-03-01T07:55:18.3393557Z,Failed to mmap. No data written: Access is denied.\r\n,,2

底线:我从团队资源管理器推送到 Visual Studio Online 存储库的代码已停止与我的 Azure 网站同步。我正在使用 git。我可能推了太多次,有些只间隔两三分钟。 (我知道,我知道,但我有充分的理由这样做。我正在尝试仅适用于实时站点的不同 Web.config 值。)如何让我的代码再次同步?

最佳答案

我进入 Kudu 调试控制台中的根站点结构“/”,并尝试删除所有顶级文件夹。有些内容不允许删除,并且您会收到错误消息。

显然,这样做时请小心!尝试删除这些文件夹后,我进行了推送,网站现已更新,一切都很好。

我还没有测试过这一点,但可能你只需要删除一个根文件夹,例如.nu​​get 文件夹,因此您应该首先尝试此操作。如果不起作用,您可以随时删除其余部分。

关于git - Visual Studio Team Services 代码未与 Azure 网站同步 - git,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42526832/

相关文章:

git - 是否可以在 git diff 中配置临时文件夹?

git - 错误 `remote: fatal: bad object 0000000000000000000000000000000000000000` 是什么意思?

c# - 以编程方式为 VSTS 生成个人访问 token

azure-devops - Visual Studio Team Services 中的 xUnit Visual Studio 测试

git - 标记 Docker Hub 版本的最佳实践是什么

Git 幽灵提交

python - 如何测试使用 Context 的 Azure Function?

c# - 如何修复 "Could not load type ' System.Runtime.Remoting.Messaging.CallContext'"

javascript - 使用 ExtJS 应用程序更新 ADAL.js token

c# - NuGet 还原后,MSBuild 在单元测试项目 (.NET Core) 上失败