从 Azure Function Portal 下载函数

问题描述 投票:0回答:1

我的 Azure Function 应用程序上有几个 Powershell 函数,它们是直接在门户中创建的,我想将它们本地下载到我的计算机上。我看到有一个选项可以手动下载包含所有内容的 zip 文件,但我尝试这样做,现在已经持续了 2 个小时,尽管我只有几个功能。有没有更快的方法来做到这一点,也许使用 Azure CLI?我在微软的文档中没有看到类似的内容,但也许有一种我还没有发现的方法?

azure azure-functions azure-powershell azure-cli
1个回答
0
投票

Azure函数可以通过两种方式从门户下载。请参阅MSDOC

来自门户用户界面:

  • 在功能应用程序概述中,选择下载应用程序内容=>选择
    Site content
    Content and Visual Studio project
    =>下载。

enter image description here

enter image description here

  • 这会将函数作为 zip 下载到本地。

使用 REST API:

  • 通过更新函数应用程序名称来浏览 URL。
https://<function_appname>.scm.azurewebsites.net/api/zip/site/wwwroot/

这会将函数内容以 zip 格式下载到本地。

enter image description here

解压后的zip文件夹的内容:

enter image description here

© www.soinside.com 2019 - 2024. All rights reserved.