如何将ASP.NET Core应用发布到ftp服务器 [英] How to publish ASP.NET Core app to ftp server
问题描述
Visual Studio publish仅支持导入Web部署.
Visual Studio publish only supports importing web deploy.
有解决方法吗?
推荐答案
Visual Studio发布配置文件支持将纯FTP作为目标.但是,它不支持SFTP.
Visual Studio publishing profiles supports pure FTP as a target. It does not support SFTP however.
这些是您应该看到的选项:
These are the options you should see:
- Web部署
- Web部署软件包
- FTP(不幸的是不支持SFTP)
- 文件系统(UNC或本地路径)
自注释ASP.NET 5以来的更新
有关项目为ASP.NET 5/vNext的详细信息,目前,Visual Studio的UI中尚不支持FTP和Web Deploy.按照以下步骤操作,其中有一个博客可以导入FTP配置文件:
With the details that the project is ASP.NET 5 / vNext, at this time, FTP and Web Deploy are not supported yet in the UI of Visual Studio. There's a blog out there following these steps to import an FTP profile:
-
打开记事本并创建一个发布配置文件以保存到您的文件系统.
Open notepad and create a publishing profile to save to your file system.
<?xml版本="1.0"编码="utf-8"?>< publishData>< publishProfile profileName ="FTP" publishMethod ="FTP" publishUrl ="ftp://ftpaddress" userName =用户名" userPWD =密码" destinationAppUrl ="http://wwwaddress"/></publishData>
<?xml version="1.0" encoding="utf-8"?> <publishData> <publishProfile profileName="FTP" publishMethod="FTP" publishUrl="ftp://ftpaddress" userName="username" userPWD="password" destinationAppUrl="http://wwwaddress" /> </publishData>
从发布目标中选择导入",然后导入发布配置文件.
Select "Import" from the publish targets and import the publishing profile.
链接到博客: http://blog.discountasp.net/publishing-an-asp-net-5-vnext-application/
这篇关于如何将ASP.NET Core应用发布到ftp服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!