fingerboy
文章10
标签4
分类3
使用 Telegram 创建无限容量的云存储

使用 Telegram 创建无限容量的云存储

TeleDrive: Unleash Unlimited Cloud Storage with Telegram

大家好!今天,我将指导您使用 TeleDrive 在 Telegram 上创建无限的云存储解决方案。这个开源项目改变了游戏规则,通过 Telegram API 提供 Google Drive/OneDrive 等功能。

Alt Text

创建云

对于那些在各种论坛或 YouTube 上寻求信息的人来说,这是微不足道的选择。我花了大约 2 个小时来解码这个问题,因为脚本正在喝咖啡休息!事实证明,该修复程序在问题存储库中非常漂亮。😂

与其浪费我们数百万美元的软件工程时间,不如让我们深入学习如何安装 TeleDrive。

搭建云储存

让我们从更新我们的软件包开始:

apt-get update

Alt Text

软后安装 Build-essentials:

apt-get install build-essential

Alt Text

接下来,让我们用 git-clone 获取 fork 存储库:

git clone https://github.com/mgilangjanuar/teledrive.git

Alt Text

如果 Git不可用,请先安装Git:

apt install git

部署过程

首先安装NVM(Node版本管理器):

wget https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh

下载完脚本后:

Alt Text

bash install.sh
source ~/.bashrc

Alt Text

确保 NVM 启动并运行:

nvm -v

用NVM安装 Node.JS 18.16.0:

nvm install v18.16.0

Alt Text

检查 Node.JS 和 NPM 到版本:

node -v
npm -v

现在,让我们进入下载的 GitHub 项目:

cd teledrive

Alt Text

我们需要安装 Yarn 和 PostgreSQL:

sudo apt install postgresql -y

Alt Text

我们用常规方式安装 TeleDrive:

chmod +x ./install.manual.sh
./install.manual.sh

Alt Text

Configuring TeleDrive

Parameters will pop up that require filling:

Alt Text

  • TG_API_ID: Application ID

  • TG_API_HASH: The hash

Alt Text

  • ADMIN_USERNAME: Telegram username (should be admin)

  • DATABASE_URL: Your postgres database

  • PORT: Operational port

  • REACT_APP_API_URL: API operation address

After a successful setup, the installation of packages kicks in. Once that’s done, a confirmation text should appear, indicating TeleDrive’s successful launch.

Alt Text

Alt Text

Alt Text

Getting APP_ID and API_HASH

Let’s head over to my.telegram.org and log in using your phone number.

Create an application and gather its data.

Alt Text

Alt Text

Alt Text

Linking to the Database

Create and import data into the database.

Alt Text

Creating:

To get started, access PostgreSQL:

arduinoCopy codepsql -U postgres
# or
sudo su - postgres
psql

Then, execute the following command:

sqlCopy codeCREATE DATABASE teledrive;

Note: If you perform these actions, you’ll also need to import server variables.

DATABASE_URL: postgresql://postgres@localhost:5432/teledrive

Then, watch in awe as TeleDrive works its magic and showcases its wonders through screenshots.

Alt Text

Alt Text

Alt Text

Alt Text

Alt Text

Alt Text

Alt Text

到此创建完毕,你可以使用它了。

本文作者:fingerboy
本文链接:http://blog.icandy.top/2024/05/21/00004/