WITHOUT 使用 GAC,有没有办法让我的所有 5 个 webApp 使用包含这些报表程序集的共享/公共 bin 文件夹,而无需我在每个 Web 应用程序的 bin 中都有 5 个程序集副本?
这些程序集通过 nuget 使用, 并将 Web 应用发布到我的部署管道中的文件夹。
>https://learn.microsoft.com/en-us/dotnet/framework/deployment/how-the-runtime-locates-assemblies 提示我在我的web.config中使用"探测路径"。我在此路径上添加了 webApp 的一个箱,并删除了生成管道中的重复程序集。
参见:https://learn.microsoft.com/en-us/dotnet/framework/configure-apps/file-schema/runtime/probing-element
例如
<configuration>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<probing privatePath="bin;bin2subbin;bin3"/>
</assemblyBinding>
</runtime>
</configuration>