如何将单个 IIS 虚拟目录 [应用程序](及其设置)迁移到另一台服务器

huangapple go评论48阅读模式
英文:

How to move individual IIS Virtual Directories [Applications] (and settings) to another server

问题

我正在尝试使用MSDeploy,如下所示:

"c:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe" -verb:sync -source:apphostconfig="Default Web Site" -dest:package=c:\dws.zip

我还查看了这个PowerShell命令:

Export-IISConfiguration -PhysicalPath "d:\appdata\IIS\Exports" -DontExportKeys

但这两者都会导出整个网站。我如何可以选择性地迁移我想要的"应用程序"呢?

例如,我只想获取下面我已经突出显示的三个应用程序。
安装BizTalk 2020时创建了BizTalkManagementService和BizTalkOperationalDataService,并部署了其中一个BizTalk应用程序,将处理BizTalk/LNGTransactionManagement。黄色部分中的三个是使用C#创建的Web服务。我使用Visual Studio将它们部署到我们的新BizTalk 2020 Dev服务器,现在我想将它们迁移到更高级的环境中。

我知道我可以复制文件,但同时可能有一些特定的IIS设置(如身份验证、日志记录等),我想要一并处理。

英文:

I was playing with using MSDeploy, as follows:

"c:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe" -verb:sync -source:apphostconfig="Default Web Site" -dest:package=c:\dws.zip 

and I also looked at this PowerShell command:

Export-IISConfiguration -PhysicalPath "d:\appdata\IIS\Exports" -DontExportKeys

but both of those export the whole website. How can I cherry-pick the "applications" that I want to move?

For example, I want to get just the three that I have highlighted below.
Installing BizTalk 2020 created BizTalkManagementService, and BizTalkOperationalDataServce, and deploying one of our BizTalk Applications will handle BizTalk/LNGTransactionManagement.
The three in yellow are web services created in C#. I deployed them to our new BizTalk 2020 Dev server using Visual Studio, now I want to migrate them to the next higher environment.
如何将单个 IIS 虚拟目录 [应用程序](及其设置)迁移到另一台服务器

I know I can copy the files, but there might be some specific IIS settings (such as authentication, logging, etc...) that I would like to handle at the same time.

答案1

得分: 1

Both MSDeploy and PowerShell's Export-IISConfiguration cmdlet provide means to export the entire IIS configuration or a specific site, but they may not provide granular control over individual applications within a site. If you want to selectively export specific applications and their associated settings from the IIS configuration and then migrate them to another environment, you may need to manually export the IIS configuration and modify it as needed.

You can export the entire site's configuration into a package using Export-IISConfiguration or msdeploy, which will include the entire site.

After exporting the configuration, you need to manually edit the exported XML file to remove unwanted applications. The exported configuration file contains XML representing IIS configuration settings, which you can use a text editor or scripting tool to make these modifications.

英文:

Both MSDeploy and PowerShell's Export-IISConfiguration cmdlet provide means to export the entire IIS configuration or a specific site, but they may not provide granular control over individual applications within a site. If you want to selectively export specific applications and their associated settings from the IIS configuration and then migrate them to another environment, you may need to manually export the IIS configuration and modify it as needed.

You can export the entire site's configuration into a package using Export-IISConfiguration or msdeploy, which will include the entire site.

After exporting the configuration, you need to manually edit the exported XML file to remove unwanted applications. The exported configuration file contains XML representing IIS configuration settings, which you can use a text editor or scripting tool to make these modifications.

huangapple
  • 本文由 发表于 2023年6月29日 00:22:51
  • 转载请务必保留本文链接:https://go.coder-hub.com/76575061.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定