Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

DotNet Core console app: An assembly specified in the application dependencies manifest

Tags:

c#

.net-core

Im just trying to run a DotNet Core console app on a Windows Server 2012 R2 but I keep getting this error:

Error: An assembly specified in the application dependencies manifest (Application.deps.json) was not found: package: 'Microsoft.Web.Administration', version: '11.1.0' path: 'lib/netstandard1.5/Microsoft.Web.Administration.dll'

The dll that is missing is inside the /publish folder... I used Dotnet publish with the correct Runtime Identifier (win81-x64)

I installed the Dotnet runtime 2.0.7 on the server

like image 639
Vincent Rutten Avatar asked May 11 '18 09:05

Vincent Rutten


People also ask

Which Assembly was not found in the application dependencies manifest?

An assembly specified in the application dependencies manifest (Microsoft.AspNetCore.AzureAppServices.HostingStartup.deps.json) was not found: package: 'Microsoft.AspNetCore.AzureAppServices.HostingStartup', version: '2.2.0'

Where is the assembly manifest stored in Windows?

The assembly manifest can be stored in either a PE file (an .exe or .dll) with Microsoft intermediate language (MSIL) code or in a standalone PE file that contains only assembly manifest information. The following illustration shows the different ways the manifest can be stored.

What are the functions of an assembly's manifest?

Each assembly's manifest performs the following functions: Enumerates the files that make up the assembly. Governs how references to the assembly's types and resources map to the files that contain their declarations and implementations. Enumerates other assemblies on which the assembly depends.

How do I create a multi-file assembly with a manifest file?

For an assembly with one associated file, the manifest is incorporated into the PE file to form a single-file assembly. You can create a multifile assembly with a standalone manifest file or with the manifest incorporated into one of the PE files in the assembly.


1 Answers

Always use the publish output when deploying to a target sever.

It can be found in

bin\Release\netcoreapp2.0\win81-x64\publish

in your case (self-contained application)

or in

bin\Release\netcoreapp2.0\publish

for framework-dependent deployments.

The output in the directories above are meant to be used in development only, since they are specific to machine and user configuration built with.

like image 112
Martin Ullrich Avatar answered Oct 03 '22 09:10

Martin Ullrich