将静态网站返回到功能代理 [英] Returning static website to Function Proxy

查看:49
本文介绍了将静态网站返回到功能代理的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当前,我正在使用Azure Functions v2.x应用程序,其中将我的工件(React构建的文件)定义为我的Function Proxies的后端(如下所示).它工作正常,显然这是连接代理与 并在用户打开my_route后返回它.但是我想知道Azure doc上的解释(用功能代理返回blob)在哪里?我在哪里可以找到他们的团队的样本? ,我正在寻找这样的东西,以更多地了解选项.例如, 在哪里使用"querystring.SharedAccessSignature"?奇怪,谷歌搜索没有得到任何结果.

还有其他任何事实上的方法可以将静态网站工件返回给我们无服务器应用程序的用户吗?


{
    " $ schema":"http://json.schemastore.org/proxies",
    代理":{
        "myProxy":{
            "matchCondition":{
                "route":"/my_route",
                方法":[
                    " GET"
                ]
            },
            "backendUri":"https://my_storage.blob.core.windows.net/my_blob/index.html",
            "requestOverrides":{
                " backend.request.querystring.SharedAccessSignature":"my_shared_access_signature"
            }
        }
    }
}

Currently I'm working on a Azure Functions v2.x app, where my artifacts (React built files) are defined as backend for my Functions Proxies (as shown below). It's working fine, and apparently this is how it should be done (?) to connect the proxy with blob and to return it once user opens my_route. But I'm wondering where is this (= returning blob with Function proxy) explained on Azure doc? Where can I find a sample by their team? , I'm looking for such a thing to learn more about options. For example, where is `querystring.SharedAccessSignature` used? It's strange that Googling this doesn't give any result.

Is there any other and de facto way to return static website artifacts to users of our serverless app? 


{
    "$schema": "http://json.schemastore.org/proxies",
    "proxies": {
        "myProxy": {
            "matchCondition": {
                "route": "/my_route",
                "methods": [
                    "GET"
                ]
            },
            "backendUri": "https://my_storage.blob.core.windows.net/my_blob/index.html",
            "requestOverrides": {
                "backend.request.querystring.SharedAccessSignature": "my_shared_access_signature"
            }
        }
    }
}

推荐答案

您实际上可以启用直接在您的存储帐户上使用静态网站功能,并在您的

这篇关于将静态网站返回到功能代理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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