且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

访问 Azure Functions 中私有 Nuget 服务器中托管的 Nuget 包

更新时间:2023-11-22 08:43:10

Krishh,

这可以像往常一样使用 nuget.config 文件:

This is possible using a nuget.config file as you normally would:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <add key="MyPrivateFeed" value="http://myhost/myfeed" />
    ... other feeds ...
  </packageSources>
  <activePackageSource>
    <add key="All" value="(Aggregate source)" />
  </activePackageSource>
</configuration>

使用 Kudu 或在此处列出的其他部署方法,将该文件复制到函数文件夹或 wwwroot(适用于所有函数),然后将使用您的配置.

Using Kudu, or another deployment method outlined here, copy that file to either the function folder or wwwroot (that would apply to all functions) and your config will be used.