我应该在应用程序中使用CORS还是CDN访问blob文件吗? [英] Should I use CORS or CDN for acessing blob files in my App?

查看:97
本文介绍了我应该在应用程序中使用CORS还是CDN访问blob文件吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,我正在将我们的应用程序迁移到Azure基础结构,但发现了问题.我们的Blob托管HTML5文件,这些文件是专有系统的输出. Blob中的HTML5文件包含一个打开到我们的处理页面的iframe.自从Blob和应用程序显示 因为不同的域(即使它们都属于我的azure帐户)也被浏览器阻止.我一直在试图更好地了解我在Azure中可用的方法.如果有帮助,请参见下面的图片...

Hello, I am migrating our app to Azure infrastructure and found a problem. Our blob hosts HTML5 files that are outputs of a proprietary system. the HTML5 files in the Blob contain an Iframe that opens to our processing page. Since the Blob and the app show as different domains (even though they both belong to my azure account) browsers will block them. Iv'e been trying to get a better understanding of the approaches i have available in Azure. Please see graphic below if it helps...

我的问题是我应该在Blob和App之间设置CORS,还是需要弄清楚如何实现Azure CDN? (该应用程序是SSL,但Blob中的文件不需要SSL).

My question is should I set up CORS between the Blob and the App or do I need to figure out how to implement an Azure CDN? (the app is SSL, but the files in the Blob do not need SSL).

提前谢谢!

Cory

推荐答案

Hi Cory,

Hi Cory,

从我所见,如果您显示的是混合内容(http和https),浏览器可能会抱怨.作为一项快速测试,您应该能够在被调用的任何服务上设置COR,以便它返回正确的标头.两种服务都应该在它们的刀片之下 配置菜单进行设置. 

From what I've seen browsers may complain if you are showing mixed content(http and https). As a quick test you should be able to setup CORs on whichever service is being called so that it returns the proper headers. Both services should a blade under their configuration menu to set this up. 


这篇关于我应该在应用程序中使用CORS还是CDN访问blob文件吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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