Umbraco Publish - Terminal Opens and Closes Immediately, No Error Output

Hi everyone,

I’m having an issue running my published Umbraco project. The app works perfectly on localhost but after publishing to a folder and running the .exe, the terminal window flashes and closes with no output at all.

What I’ve already tried:

  • Created the missing wwwroot/media/ folder manually (this fixed a DirectoryNotFoundException I was getting before)

  • After fixing that, the terminal still opens and closes immediately with no error message

Environment:

  • .NET 10

  • Umbraco CMS

  • Blazor frontend

  • Published as folder (not self-contained)

Previous error (now fixed):

Unhandled exception. System.IO.DirectoryNotFoundException:
C:\...\publish\wwwroot\media\
at Microsoft.Extensions.FileProviders.PhysicalFileProvider..ctor
at Umbraco.Cms.Core.IO.PhysicalFileSystem.Create()

Current behavior: Running the .exe directly causes the terminal to flash open and close with no visible output. I can’t see any error message.

Has anyone experienced this? Any help is appreciated, thanks!

hi enes

did u check connectionString - appsettings.json ?

make sure it points to accessible db

Create the media directory and it should run.

But I do think the .exe will just close the window anyway, or just show a completely blank output when it has been built in Release mode.

You could run the app from a Terminal (cmd/powershell) window and this would remain visible with any feedback it has to provide. So if there is an exception it would be displayed.