一般博客的资源动静分离,动态资源传到对象存储,实现服务器瘦身,并启用CDN加速。
WordPress上也有许多第三方插件帮你完成设置,网上也有许多指导,但是最近笔者尝试阿里云OSS及七牛云存储都失败了,没有响应。
后来发现要再开一个ossftp端口。
在有公网的服务器上安装 ftp server
cd ossftp-1.0.2-linux-mac
解压:sudo unzip ossftp-1.0.2-linux-mac.zip
运行脚本bash start.sh
上述步骤会启动一个FTP server, 默认监听在127.0.0.1的2048端口。同时,为了方便您对FTP server的状态进行管控,还会启动一个web服务器,监听在127.0.0.1的8192端口。
可以按Ctrl + C 结束了
阿里云/七牛插件启动后,可以看见bucket开始有文件
若是从头开始设置,可按以下教程(笔者未亲自验证):
<a href="https://help.aliyun.com/document_detail/32193.html?spm=a2c4g.11186623.6.1059.1Op1BX">Wordpress如何存储远程附件到oss</a>
<a href="https://help.aliyun.com/document_detail/32187.html?spm=a2c4g.11186623.6.1069.FDaW9A">有关Object命令</a>
点击下面的连接可以获得阿里云所有产品幸运券
<a href="https://promotion.aliyun.com/ntms/act/ambassador/sharetouser.html?userCode=pfj105fy&utm_source=pfj105fy">https://promotion.aliyun.com/ntms/act/ambassador/sharetouser.html?userCode=pfj105fy&utm_source=pfj105fy</a>
<a href="https://developer.qiniu.com/kodo/tools/1302/qshell">qshell</a>
是利用七牛文档上公开的API实现的一个方便开发者测试和使用七牛API服务的命令行工具。
<a href="https://liuyanzhao.com/2176.html">配置七牛自定义域名cdn加速</a>
点下面链接加入七牛认证后每月10G免费
<a href="https://portal.qiniu.com/signup?code=3lp25vct5v1hu">https://portal.qiniu.com/signup?code=3lp25vct5v1hu</a>