解决阿里云OSS无法使用图片URL访问,访问时提示下载

问题原因

阿里云OSS无法使用图片URL访问,访问时提示下载

访问oss生成的图片路径,访问被禁止,返回一堆错误的xml文件

问题展示

This XML file does not appear to have any style information associated with it. The document tree is shown below.
<Error>
<Code>AccessDenied</Code>
<Message>
You have no right to access this object because of bucket acl.
</Message>
<RequestId>5BCD96982327B532D3303199</RequestId>
<HostId>miaoqs.oss-cn-hangzhou.aliyuncs.com</HostId>
</Error>

解决办法

演示解决结果

猜你喜欢

转载自blog.csdn.net/wildwolf_001/article/details/83275924
今日推荐