Nov 302019
 
 November 30, 2019  Posted by at 8:35 am .NET Core, Dev Ops  Add comments

After a an update to the .NET Core SDK and TeamCity we started having problems with one of our services during deployment. The service is built as a self-contained application, and we use TeamCity for our build steps. The .NET CLI plugin in TeamCity passes in an rsp file after the arguments and this is what is causing the the problem.

[15:46:34] [publish] Starting: "C:\Program Files\dotnet\dotnet.exe" publish services\Konstrukt.Service.Data\DataServiceBroker\DataServiceBroker.csproj --framework netcoreapp2.1 --configuration Release --runtime win7-x64 --self-contained @C:\TeamCity\buildAgent\temp\agentTmp\4.rsp

The error:

error MSB4030: "@C:\TeamCity\buildAgent6\temp\agentTmp\4.rsp" is an invalid value for the "IsSelfContained" parameter of the "GenerateDepsFile" task. The "IsSelfContained" parameter is of type "System.Boolean". [C:\TeamCity\buildAgent\work\fd104265242f4376\services\Konstrukt.Service.Data\DataService\DataService.csproj]

The solution is simple, just pass in a boolean. If you are passing in anything after –self-contained you have to set the boolean explicitly (see issue here) :

Error MSB4030 Teamcity

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)

What is 7 + 4 ?
Please leave these two fields as-is:
IMPORTANT! To be able to proceed, you need to solve the following simple math (so we know that you are a human) :-)