Skip to content
This repository was archived by the owner on Nov 21, 2018. It is now read-only.
This repository was archived by the owner on Nov 21, 2018. It is now read-only.

ASP.NET TargetManifestFiles should use $(SelfContained) property #175

@eerhardt

Description

@eerhardt

See

<PublishWithAspNetCoreTargetManifest Condition="'$(PublishWithAspNetCoreTargetManifest)'=='' and '$(RuntimeIdentifier)'=='' and '$(RuntimeIdentifiers)'=='' and '$(PublishableProject)'=='true'">true</PublishWithAspNetCoreTargetManifest>

and
Condition="'$(RuntimeIdentifier)'!='' or '$(RuntimeIdentifiers)'!=''" />

These conditions shouldn't be using '$(RuntimeIdentifier)'=='' and '$(RuntimeIdentifiers)'=='', but instead it should use the new $(SelfContained) property instead.

In .NET Core 2.0, we now have a 3rd app model: Rid-specific, Shared Framework apps (sometimes referred to as a "low-fat app"). This means, I can publish an app that runs on the Shared Framework, but it only uses the win-x64 (or any other RID) assets. It isn't truly "portable" meaning it will run on any platform. This trims down on the size of the app, as it doesn't need to publish assets for other platforms that it won't run on. See dotnet/sdk#1053.

Thus, if someone tried publishing a Rid-specific, Shared Framework ASP.NET app and wanted to use the ASP.NET runtime store, these checks wouldn't be correct.

To fix this, simply change the RuntimeIdentifier checks to use SelfContained instead. Target manifest files shouldn't be used with SelfContained apps. But they should default to be used when the app isn't SelfContained.

/cc @JunTaoLuo @nguerrera

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions