Visual Studio Publish / Web Deploy

Web deploy can be used to upload a site developed through Visual Studio to the web server.  Using web deploy can help avoid issues like missing assemblies that might occur when uploading a Visual Studio project via FTP.  Note that the steps below are for Visual Studio 2017.  Additional information relating to Deployment Mode in Core can be found at the bottom of the article.
 
 
Set up a publish profile
 
In Visual Studio, right click the project and select Publish from the menu.
 
 
 
 
Select IIS, FTP, etc as the publish target and click Publish.
 
 
 
 
The web deploy connection settings required are
 
Server:  https://web###.discountasp.net (replace "web###" with the Server from DiscountASP Control Panel > Account Info / Edit > Web Deploy Publishing Information; see below)
Site name:  the website's domain name
User name:  Control Panel Login
Password:  Same as Control Panel Password
Destination URL:  optional and can be left blank; used for a redirection after the site is successfully deployed
 
After entering the connection information, click Validate Connection.  If there is a check mark and the project has no database, click Save.  If there is a database, click Next to set up the connection string.
 
If an error is returned on validation check and the publish connection settings have been verified as being correct, open a ticket with the Support Department and provide the error in case Web Management Service needs to be manually restarted.
 
 
 
 
Web Deploy Publishing Information
 
The connection settings for Web Deploy can be reviewed at DiscountASP Control Panel > Account Info / Edit > Web Deploy Publishing Information
 
 
 
 
Connection String
 
If a connection string is required for the deployed project, a DiscountASP database connection string can be found at DiscountASP Control Panel > MS SQL Manager > Manage (applicable database).  Note that the example Connection String does not contain the database password in plain text, so it will need to be updated after copying it to Visual Studio.  After adding the connection string, Save.
 
 
 
 
Publish
 
After saving the publish profile, the left pane in Visual Studio should update.  Click Publish to deploy the project to the web server.
 
 
 
 
Core
 
Before deploying a Core application, first review the supported versions.  If the project is targeting a newer version than what is currently supported, it should be changed to Self-Contained prior to deployment.  The Deployment Mode is found in the Publish Settings (click Next when viewing the Publish Connection).  Select "Self-Contained" from the drop-down, Save and Publish.