记录一下通过Cloudflare的worker搭建Google Drive目录程序
说明
快速部署
- 打开https://install.achirou.workers.dev 或者 https://goindex-quick-install.glitch.me
- 授权并获取授权码
- 将代码部署到 Cloudflare Workers
部署
- 开启Google Drive API
- 创建一个 OAuth client ID
- 本地安装rclone
- 使用
rclone
获取refresh_token
- 下载
index.js
(https://github.com/Aicirou/goindex-theme-acrou/tree/master/go2index) 然后替换client_id
,client_secret
,refresh_token
为你刚刚获取到的 - 把代码部署到Cloudflare Workers
补充
建议使用第二种部署流程,这样获取到的client ID
和client_secret
是自己单独使用的,而使用快速部署获取到的,是很多人共用的,高峰期速度很慢!