Aliyun-oss-storage icon indicating copy to clipboard operation
Aliyun-oss-storage copied to clipboard

优化了OSS自定义域名,Storage::url获取自已的资源地址

Open jackcoco opened this issue 5 years ago • 2 comments

AliOssServiceProvider.php 修改内部节点为:$epInternal = empty($config['endpoint_internal']) ? $endPoint : $config['endpoint_internal']; // 内部节点 $client = new OssClient($accessId, $accessKey, $epInternal);

filesystems.php 参数描述:
···
'endpoint' => '外网访问节点', 'endpoint_internal' => '内网节点', 'cdnDomain' => '自定义OSS外网访问域名', 'ssl' => true, 'isCName' => true, ····

修改后: Storage::url($yourpath); 就可以获取正常的自定义url

jackcoco avatar May 30 '19 06:05 jackcoco

AccessDenied: You have no right to access this object because of bucket acl.

被这个问题快弄疯了,各种查,差点提了阿里云工单...

最后才发现是$epInternal这个问题导致的...

ahu avatar Dec 26 '19 03:12 ahu

oss 配置 endpoint 和 cdnDomain 时,不加 https:// 就正常,不用修改代码

LinXueYi avatar Mar 21 '22 07:03 LinXueYi