Goindex免服务器谷歌网盘索引 | Serverless Google drive indexing
Goindex将Google Drive通过Cloudflare网络生成无需科学上网即可访问的在线文件目录,具备轻量,设置简单,无服务器的特点,可以直接列出你谷歌网盘的所有文件,还可以在线观看某些格式的视频文件。
Combining the power of Cloudflare Workers and Google Drive will allow you to index you files on the browser on Cloudflare Workers.
目录 / LIST
# 获取配置参数 | Get parameters
- 先安装rclone,并配置好你的谷歌网盘,个人推荐无限容量的团队盘,如果没有,可以联系 Maxh 免费领取一个。
- First you should have rclone installed, and have google drive config set as well. It is recommended to add an shared team drive that have unlimited storage. Contact Maxh to get one for free.
你可能会感兴趣 | Maybe interested in
- 配置完成后,用filebrowser打开rclone的配置文件
/root/.config/rclone/rclone.conf
,记下里面的对应的refresh_token
,以及team_drive
共享团队盘的代码。 - After the configuration is complete, use the filebrowser to open the rclone configuration file
/root/.config/rclone/rclone.conf
, write down the correspondingrefresh_token
, and theteam_drive
code.
你可能会感兴趣 | Maybe interested in
# 获取workers代码 | Get workers code
- 接下来到donwa/goindex · GitHub把
index.js
代码复制下来,并且把刚才获取的refresh_token
和team_drive
填入如下相应位置。 - Next, copy the
index.js
code in donwa/goindex · GitHub, and fill in the following locations with therefresh_token
andteam_drive
you just got.
var authConfig = {
"siteName": "Marsgrid", // 网站名称
"root_pass": "", // 根目录密码,优先于.password
"version" : "1.0.6", // 程序版本
"theme" : "material", // material classic
"client_id": "202264815644.apps.googleusercontent.com",
"client_secret": "X4Z3ca8xfWDb1Voo-F9a7ZxJ",
"refresh_token": "1/6MO******", // 授权 token | refresh_token
"root": "0AA******" // 根目录ID | team_drive
};
# 部署到cloudflare | deployment in cloudflare
- 登陆Cloudflare,依次选择
Workers
、Create a worker
。 - Log in to Cloudflare and select
Workers
, thenCreate a worker
.
- 把刚才准备好的代码复制到左边,然后点击
Save and Deploy
完成部署。 - Copy the code you just prepared to the left and click
Save and Deploy
to complete the deployment.
# 绑定域名 | Binding domain name
- 部署完成后域名可能会很长,参照以下步骤绑定你自己的三级域名。首先需要先将自己的域名转到cloudflare,然后点自己域名的DNS设置,解析一个A记录,IP地址随意,其他默认。
- After the deployment is complete, the domain name may be very long. Follow the steps below to bind your own third-level domain name. First, you need to transfer your domain name to cloudflare, then click the DNS setting of your domain name, add an A record, the IP address is arbitrary, and other by default.
- 设置完毕后再来到workers页面,点击
Add route
,输入刚才设置的三级域名,http
或https
随意,记得末尾要添加/*
,Worker
选择刚才新建的那个。 - After setting, go to the workers page, click
Add route
, enter the three-level domain name you just set, type inhttp
orhttps
as you wish. Feel free to add/*
at the end, andWorker
select the one you just created.
# 在线播放 | Stream online
- 打开nPlayer内置的浏览器输入刚才配置的域名即可在线播放。
- Open nPlayer’s built-in browser and enter the domain name you just configured to go streaming.
# 参考指南 | User Guide
- 如果你想了解更多Goindex的使用方法,可以访问下方的Github项目页面。
- If you want to learn more about how to use Goindex, you can visit the GitHub page.
END
• 本文作者 | Author info >> MAXH
• 来源链接 | Source link >> Goindex免服务器谷歌网盘索引 | Serverless Google drive indexing
• 发表评论 | Make comments >>
MARSGRID