ビルド サーバーで Microsoft.WebApplication.targets が見つかりませんでした。解決策は何ですか? 質問する

ビルド サーバーで Microsoft.WebApplication.targets が見つかりませんでした。解決策は何ですか? 質問する

ビルド サーバーでプロジェクトをビルドしようとすると、次のエラーが発生します。

Microsoft (R) Build Engine Version 4.0.30319.1
error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\TeamData\Microsoft.Data.Schema.SqlTasks.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.
error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.
error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.

数か月前、ビルド サーバーに Visual Studio 2010 をインストールしてこの問題を解決しました。しかし、現在は新しいサーバーを最初からセットアップしており、この問題を解決するためのより良い解決策があるかどうかを知りたいです。

ベストアンサー1

質問のタイトルに答えるには(ただし、得られる出力に関する質問には答えません):

ウェブアプリケーションだけの場合は、開発マシンからビルドサーバーに次のフォルダをコピーすると、この問題が解決します。

C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplications

ビルドが中断される状況に応じて x86 を削除します。他のプロジェクト タイプがある場合は、msbuild フォルダー全体をコピーする必要がある可能性があります。

おすすめ記事