Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Publishing from Visual Studio 2015

I am trying to publish my ASP.NET 5 MVC6 application to godaddy server from Visual Studio 2015. I have imported publish profile from my server and I am able to validate the connection. However, when I publish my app I have the following error:

ERROR_USER_UNAUTHORIZED

Web deployment task failed. (Connected to the remote computer ("XXXXXXX") using the Web Management Service, but could not authorize. Make sure that you are using the correct user name and password, that the site you are connecting to exists, and that the credentials represent a user who has permissions to access the site.

The credentials are valid, I can publish VS2013 sample project from VS2015, but I can not publish VS2015 sample project as well as my app from VS2015 with the same credentials.

The user is an admin on the server.

like image 691
koryakinp Avatar asked Nov 12 '15 07:11

koryakinp


People also ask

How do I publish a file in Visual Studio?

Right-click on the project (not the solution) in Solution Explorer and select Publish. In the Publish tab, select Publish. Visual Studio writes the files that comprise your application to the local file system. The Publish tab now shows a single profile, FolderProfile.

How do I publish a Visual Studio project to my website?

Get started. In Solution Explorer, right-click your project and choose Publish. If you're publishing this web app for the first time, next you see the Publish wizard. Visual Studio filters the list of destinations depending on the type of web app.

What does it mean to publish in Visual Studio?

Publishing creates the set of files that are needed to run your application. To deploy the files, copy them to the target machine.


1 Answers

The first thing you need to check is if GoDaddy supports 4.5.1 on their server. Once this is confirmed? We can start working!

Helios (the shim between IIS and ASP.NET 5) requires at least 4.5.1 to run so this is why it's essential.

Only thing missing is running a dnu publish and making sure that you have a web.config with this section in it:

<system.webServer>
  <modules runAllManagedModulesForAllRequests="true" />
</system.webServer>

If it doesn't work, I would get in touch with GoDaddy for some support. If they do not support the latest version of the framework, you might have to revert to MVC 5 or switch to azure-web-sites if you really want to enable asp.net-mvc-6.

like image 130
Maxime Rouiller Avatar answered Oct 20 '22 03:10

Maxime Rouiller