发布和部署控制台应用程序C#

发布和部署控制台应用程序C#

问题描述:

大家好,发布和部署应用程序是否相同?
发布的目的是什么?

Hi all, do publish & deploy application is the same?
What is the purpose of publishing?

通过发布以及创建setup.exe(安装和部署),您将获得预编译的站点.

两者之间的区别在于:

发布:右键单击该网站,然后单击发布网站".在这里,您可以指定一个文件夹,将在该文件夹中发布预编译的网站.然后,您可以将网站ftp.其他选项是您可以直接指定ftp位置.

安装和部署:创建一个新的安装和部署项目,添加项目输出,最后创建一个setup.exe文件.您需要登录到要在其上安装应用程序的服务器.在那里,您需要运行setup.exe文件.

因此,如果要在共享托管环境上托管应用程序,则应使用发布.而且,如果要创建要从网站下载的Web应用程序产品,则最好创建一个setup.exe(部署).
You will get a precompiled site by publishing as well as by creating a setup.exe (setup and deployment)

The difference between the two is that:

Publishing: you right click on the website and click on ''Publish Web Site''. Here you can specify a folder where the precompiled website will be published. Then you can ftp the website. Other option is you can directly specify the ftp location.

Setup and Deployment: you create a new setup and deployment project, add the project output and finally create a setup.exe file. You need to login into the server on which you want to install the application. There you need to run the setup.exe file.

So, if you are hosting your application on a shared hosting environment, you should use publishing. And if you are creating a web application product to be downloaded from your website, you should ideally create a setup.exe (deploy).