简体   繁体   English

在OVH对象存储中永久启用CORS(OpenStack swift)

[英]Enable permanently CORS in OVH Object Storage (OpenStack swift)

I can enable CORS in OVH Object Storage (that uses OpenStack Swift) using this command 我可以使用此命令在OVH对象存储(使用OpenStack Swift)中启用CORS

curl -i -XPUT -H "X-Auth-Token: xxxxxxxxxxx" -H "X-Container-Meta-Access-Control-Allow-Origin: *" https://storage.sbg1.cloud.ovh.net/v1/AUTH_yyyyyyy/repository

and everything works well. 一切都运作良好。 But after a period of time (that is completely random) this option is reset. 但经过一段时间(完全随机)后,此选项将重置。 Do you know why and how to solve that? 你知道为什么以及如何解决这个问题吗?

I discovered the answer to this issue. 我发现了这个问题的答案。 When you visit your OVH control panel and enter the cloud containers section, their CP resets the CORS. 当您访问OVH控制面板并进入云容器部分时,它们的CP会重置CORS。 As long as you don't log into and visit this area, your CORS should remain as you have set it. 只要您不登录并访问此区域,您的CORS应保持原样。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM