• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Issue Please help an absolute newbie publish a .NET Core application to Plesk

alexander.hoffen

New Pleskian
Hi!

After countless of hours spent googling, I really need some help to understand how publishing a website works. Bear with me -- I know how to code, but this is my first time actually publishing something. Perhaps I'm just stupid, and am unable to understand the online guides, but I think I'm almost there.

I have a Plesk server at one of the big hosting websites. It's a windows server. They gave me a .publishsettings-file that contains the following xml (though naturally the parameters aren't blank):

Code:
<publishData><publishProfile profileName="" publishMethod="" publishUrl="" msdeploySite="" userName="" destinationAppUrl="" controlPanelLink=""/></publishData>

I right-clicked on my profile in Visual Studio, selected Publish, imported the file, and pressed the publish button. The result was that files were uploaded to Plesk server in the following structure:

d781e06b21199b7499e07fdf229035e2.png


The wwwroot-folder contains css, js, and images, but not html or cshtml. As a web developer, the first thing that confused me is the lack of cshtml-files, but I figured maybe they aren't needed because of how .NET handles dlls? Regardless, going to my website just gives me a "500 - Internal server error".

Can someone explain to me, as if I was an eight year-old, what exactly I need to do to get my website up and running. Should I change a publish-file to include my cshtml-files? Do I need to change some settings, either on the server or in VS? Do I need to change the project structure? I feel so lost, and neither the Plesk nor VS docs have been of much use to me.

I'm really sorry if this is a stupid question, and thank you very much for your patience.
 
Hello,

let's try to split this issue into several small problems and questions
1) to understand if problem is related to webdeploy, you can try to switch to local directory publishing in Visual Studio and compare content produced locally with content uploaded using publishsettings.
2) in case you have 500 error on your site, you can try to log in to your server (if it is possible), and request your page locally. In this case IIS will produce more detailed errors for your request. If you cannot open your site locally, you can try to add the following section in your web.config
<system.web>
<customErrors mode="Off" />
...
</system.web>
in this case you will see more information about error, which can help to understand root cause.

3) which version of .NET Core are you using? starting from ASP.NET Core 2.2 new model of IIS integration is used, and in order to make it work, you need either:
a) to have IIS application pool switched into 64-bit mode. Unfortunately, you cannot do this in Plesk Onyx 17.8 (this functionality was added in Plesk Obsidian 18.0 which is currently RC). But you can change this manually in IIS (again, if you have access to the server).
b) configure your application to not use new integration with IIS for your 2.2 application
some details about this you can read in this thread: Question - ANCM In-Process Handler Load Failure on asp.net core 2.2 app

I hope this can help you.
 
Back
Top