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.

asp.net core bin folder on publish to group all binaries

See original GitHub issue

Is there an existing issue for this?

  • I have searched the existing issues

Is your feature request related to a problem? Please describe the problem.

When publishing an ASP.net Core app we get a folder with lots of folders and dll files (+ folders for each culture), appsettings.json, web.config

Describe the solution you’d like

it would be much better to have a bin folder for all the dll files and rest non wwwroot folders

Additional context

Might not be a big issue for users of automatic/azure deployments, but for users of shared hosting and unperfect file managers, where we have to pick and delete files before unzipping the deployment zip it makes things harder.

On each deployment I have to delete all files, except: .well-known, my custom App_Data folder(s), wwwroot sometimes, appsettings.json sometimes.

And when using mvcBuilder.AddRazorRuntimeCompilation() there’s also the Views folder.

So basically I need to do a whole lot of checkbox ticking and if all the dlls/runtimes folders and files would be in a bin folder it would make things a lot easier.

Issue Analytics

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

github_iconTop GitHub Comments

2reactions
davidfowlcommented, May 1, 2023

There would need to be a large demand for us to investigate adding this feature. We can leave this issue open and see how big of a pain point it is in general for customers. I assume you are using a traditional windows shared hoster? If not, can you share more details on your deployment process?

In general, we try as hard as possible to keep ASP.NET Core applications looking as similar to normal console applications as possible to avoid any differences in runtime behavior that have undesirable follow on effects (like loading assemblies from a different location or changing the loading semantics).

1reaction
davidfowlcommented, Apr 30, 2023

I can’t see us bringing back the bin folder to make uploading to shared hosters easier (ftp?). If your shared hosted supports web deploy; then it’s possible to automate the delete and push (it can diff what’s local and what’s remote).

It might be possible to configure the settings in a way that makes this work, but it’s a little tricky if you are using IIS

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to publish additional files into bin folder
I have a similar setup. 2 projects in my solution, one .NET Core and the other C++. When I am going to publish...
Read more >
Visual Studio publish to folder is publishing all folders even ...
I have a old asp.net framework application that I've been tasked with fixing. It's been coded by an over-seas company and it's been...
Read more >
Publishing A Single EXE File In .NET Core 3.0
Publish the project from the current directory; Build the project to run on Windows 64 bit machines; Build in release configuration mode; Publish...
Read more >
Tutorial: Deploying an ASP.NET core application on Linux ...
Compile and run your web application locally. Publish your application artifacts to an output directory. The artifacts include the compiled source code, runtime ......
Read more >
.NET Core SDK Projects: Controlling Output Folders and ...
NET SDK projects this is more complicated as there's no simple way to exclude dependencies quite so easily. Either everything but the primary ......
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