Open calanchenlins opened 3 years ago
@hoyosjs @josalem where is the doc on our self-contained tool install?
All the current shipping vehicles for the diagnostics tools require an externally installed runtime.
We've looked at doing a self-contained version of the tools, but the size per tool started to get large even with trimming.
I don't think this will be done in the immediate future due to our existing backlog, but it is something we want to do at some point.
In the meantime, you can build the tools from source as self-contained deployments and copy/paste the output to your production environment. Let me know if you want some guidance on that 😄
All the current shipping vehicles for the diagnostics tools require an externally installed runtime.
We've looked at doing a self-contained version of the tools, but the size per tool started to get large even with trimming.
I don't think this will be done in the immediate future due to our existing backlog, but it is something we want to do at some point.
In the meantime, you can build the tools from source as self-contained deployments and copy/paste the output to your production environment. Let me know if you want some guidance on that 😄
It's complicated for me to publish from source code. When I run command: dotnet publish /p:BundleTools=false -c Release -r linux-x64
in /src/Tools/dotnet-counters
directory, it shows error NETSDK1053: pack as tool don't support self-contained
.
If I copy Microsoft.Diagnostics.NETCore.Client、dotnet-counters project and relevant document to other directory, Specify the package version,edit .csproj file.
publish command with self-contained will Execute successfully. It would be good if you could give me some guidance.
@calanchenlins counters is an easier one to do in that sense. dotnet-dump and dotnet-sos might require a little more work.
SelfContained
to true and PublishTrimmed
to false in https://github.com/dotnet/diagnostics/blob/5b200d3f52e51d0a96e9190f1fcf7c282550ed7c/src/Tools/Directory.Build.props#L13-L16SupportedRids
and limit _ProjectToBundle
only to the tools you care about in https://github.com/dotnet/diagnostics/blob/5b200d3f52e51d0a96e9190f1fcf7c282550ed7c/src/singlefile-tools.proj#L13-L14build.cmd -bundletools -c release
. The output will be in artifacts\bundledtools\Release\<RID>\
. Mind you, each one is 70 mb.
@hoyosjs Thanks for your guidance! Through your method I have published successfully.
We publish DotNetCore App on production environments with self-contained. In order to use diagnostic tools we must install runtime on PROD server or client computer. Any plans to release these tools with self-contained mode?