question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Publish not working for self contained app? (rc2)

See original GitHub issue

Steps to reproduce

  • Create a “Console Application (.NET Core)” from Visual Studio
  • Add a runtime “win10-x64” as specified in the documentation app-types
  • run dotnet publish --configuration Release --runtime win10-x64

Final content of the project.json:

{
  "version": "1.0.0-*",
  "buildOptions": {
    "emitEntryPoint": true
  },

  "dependencies": {
    "Microsoft.NETCore.App": {
      "type": "platform",
      "version": "1.0.0-rc2-3002702"
    }
  },

  "frameworks": {
    "netcoreapp1.0": {
      "imports": "dnxcore50"
    }
  },
  "runtimes": {
    "win10-x64": { }
  }
}

Expected behavior

The full runtime, dotnet.exe… in the publish folder.

Actual behavior

There is just there the DLL of the main, but no runtime and exe

dotnet-cli-pubish

Environment data

dotnet --info output:

.NET Command Line Tools (1.0.0-preview1-002702)

Product Information:
 Version:     1.0.0-preview1-002702
 Commit Sha:  6cde21225e

Runtime Environment:
 OS Name:     Windows
 OS Version:  10.0.10586
 OS Platform: Windows
 RID:         win10-x64

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
ericstjcommented, May 23, 2016

The only reason not to use win10-x64 was due to an issue with the CLRCompression package. @ianhays was working on that. I believe that is still not fixed in the latest packages so you should avoid using win10 until that is fixed. https://github.com/dotnet/corefx/issues/7436

0reactions
guardrexcommented, May 23, 2016

@xoofx Yes, they are forward compat, so you can use win7-x64 on forward platforms from Win7+ and IIS 7.5+, while win81-x64 would be Win81+ and IIS 8.5+.

@ericstj will probably tell us if the prior advice holds regarding win10-x64, and @blackdwarf might want to change that doc if it makes more sense to make it say either win7-x64 or win81-x64.

I am a little concerned about devs seeing win10-x64 in various spots and thinking, ‘Well … that would be Win10+ and IIS 10+.’ … and start using it for web apps on WS2016/Nano, where perhaps it really should be win81-x64.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot publish self-contained .NET app that
No matter what, .NET will not allow me to publish the app self-contained. It fills the export directory with dozens of files.
Read more >
Should I use self-contained or framework-dependent ...
In this post I compare the impact of the framework-dependent vs self-contained mode on Docker image size, taking layer caching into account.
Read more >
docker - Problems with .net-core self contained publish
I`m trying to publish a self-contained app, made in .net-core, following the steps in https://learn.microsoft.com/en-us/dotnet/articles/core/ ...
Read more >
Jumping to Asp Net Core RC2 with DotNet CLI
We wanted a self contained application. DotNet lets one publish for a specific runtime (i.e. like for Docker or our local Windows, ...
Read more >
Announcing .NET 5.0 RC 2
NET Microsoft site has been running on . ... It is now running RC2. ... We also intend to support self-contained and single...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found