获取上传到云存储的对象的公共 URL [英] Get public url for object uploaded on cloud storage
本文介绍了获取上传到云存储的对象的公共 URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
I uploaded a pdf file on cloud storage. But when i access url https://storage.cloud.google.com/[BUCKET]/[FILE].jpg i am redirected to google signin page. Is there any way to get a public url which gives direct access to file and doesnt have CORS issues.
解决方案
It was silly mistake. Use
storage.googleapis.com/<bucketName>/<fileName>
instead of
storage.cloud.google .com/<bucketName>/<fileName>
这篇关于获取上传到云存储的对象的公共 URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文