NextCloud使用阿里云OSS作为默认存储

在config.php配置文件的 );前插入下面的代码

'objectstore' => [
        'class' => '\\OC\\Files\\ObjectStore\\S3',
        'arguments' => [
                'bucket' => 'xxx', //存储桶名称
                'autocreate' => false,
                'key'    => 'LTAIxxxxxxx', //AK
                'secret' => 'y1YdyUiIxxxxx', //SK
                'hostname' => 'oss-ap-southeast-1.aliyuncs.com', //输入对应的Endpoint
                'port' => "",
                'use_ssl' => false,
                'region' => 'oss-ap-southeast-1.aliyuncs.com', //输入对应的Endpoint
                // required for some non Amazon S3 implementations
                'use_path_style'=>false
        ],
],

参考:

https://docs.nextcloud.com/server/stable/admin_manual/configuration_files/primary_storage.html?highlight=s3

Comments

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注