如何在Microsoft Azure Function Apps中使用外部程序集? [英] How do I use external assemblies with Microsoft Azure Function Apps?

查看:58
本文介绍了如何在Microsoft Azure Function Apps中使用外部程序集?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

文档说,您可以放bin文件夹中的DLL并使用特殊的#r语法引用它,但是在Azure门户中,我找不到如何上传这些DLL.这可能吗?如果可以,应该如何实现?

The documentation says that you can put a DLL in a bin folder and reference it using a special #r syntax, however in the Azure portal I cannot find how to upload these DLLs. Is this possible, and if so, how is that supposed to be accomplished?

推荐答案

这是可能的.

您可以使用Kudu上传二进制文件:

You can use Kudu to upload your binaries:

  1. 打开应用程序的Kudu门户.如果您的Functional App的URL为samplefunctions.azurewebsites.net,请转到samplefunctions.scm.azurewebsites.net.

单击Debug console菜单,然后选择PowerShell.这将打开一个PowerShell控制台以及一个文件浏览器.导航到D:\home\site\wwwroot.

Click on the Debug console menu and select PowerShell. This will open up a PowerShell console plus a file explorer. Navigate to D:\home\site\wwwroot.

在那里您应该看到一个以现有功能命名的文件夹.导航到该文件夹​​,然后将二进制文件拖放到bin文件夹中.

There you should see a folder which is named after your existing function. Navigate to that folder and drag-n-drop your binaries inside bin folder.

现在您可以将它们与#r指令一起使用.

Now you can use them with #r directive.

我认为您还应该能够将库的连续部署配置为Function(例如,从Git存储库中).转到Function app settings-> Configure Continuous Integration.

I think you should also be able to configure the continuous deployment of your libraries to Functions (e.g. from a Git repo). Go to Function app settings -> Configure Continuous Integration.

这篇关于如何在Microsoft Azure Function Apps中使用外部程序集?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆