neonKUBE icon indicating copy to clipboard operation
neonKUBE copied to clipboard

neon-cli is including ASPNETCORE components which is bloating the install by 16MB

Open jefflill opened this issue 2 years ago • 1 comments

One of the libraries must be referencing this by mistake or we need a new library for ASPNET stuff.

jefflill avatar Sep 15 '22 15:09 jefflill

I poked around this for a bit and removed some ASPNETCORE related package references in the solution but that's still not helping.

It looks like all of these additional files are brought in when publishing the app. I'm still not sure why these are being referenced, so more research to do.

I wonder if it might be possible to just delete these files when generating the installers.

jefflill avatar Oct 01 '22 02:10 jefflill

I finally figured this out. The problem is that the Neon.Kube.csproj project is referencing the NSwag.MSBuild package for some reason:

image

This must be bringing ASPNET in. I'm going to remove this.

jefflill avatar Nov 06 '22 16:11 jefflill

FIXED

jefflill avatar Nov 06 '22 16:11 jefflill

This is still a problem. I've used the divide-and-conquer technique and narrowed this down to Neon.Kube.Setup.

The problem is that this project is referencing Neon.Kube.Operator. That assembly is only intended to be referenced by actual operator services, not other libraries or non-operator applications because it will bring in ASP.NET and potentially other junk we don't need. Non-operators will reference Neon.Kube.Resources to use CRDs generated by the operator.

jefflill avatar Nov 07 '22 16:11 jefflill

Actually FIXED

jefflill avatar Nov 07 '22 16:11 jefflill