Giter Site home page Giter Site logo

mirror2gdrive's Introduction

Mirror2GDrive

Hello there, ๐Ÿ‘ฝ I am a Telegram Bot that can download files using Aria2/Qbittorrent and upload them to your GDrive or Telegram. I can run only on Linux x86_64/amd64 system.

Available Commands

start         - ๐Ÿ‘ฝ Start the bot
mirror        - ๐Ÿ—ณ Mirror file using Aria2
qbmirror      - ๐Ÿงฒ Mirror file using Qbittorrent
unzipmirror   - ๐Ÿ—ƒ๏ธ Mirror & unzip using Aria2
qbunzipmirror - ๐Ÿซง Mirror & unzip using Qbittorrent
leech         - ๐Ÿงฉ Mirror & leech using Aria2
qbleech       - ๐ŸŒ€ Mirror and leech using Qbittorrent
unzipleech    - ๐Ÿงฌ Unzip and leech
task          - ๐Ÿ“ฅ Show the task list
ngrok         - ๐ŸŒ Show Ngrok URL
stats         - โš™๏ธ Show system info
log           - ๐Ÿ“„ Get runtime log file

Prepare config.env file

Create an env file in Github Gist or any other place but make sure to provide the direct download link of that file.

PICKLE_FILE_URL = ""
BOT_TOKEN = ""
TG_API_ID = ""
TG_API_HASH = ""
# To upload files in telegram
USER_SESSION_STRING = ""
# Authorized users to use the bot
USER_LIST = '[12345, 67890]'
# Drive/Folder ID to upload files
GDRIVE_FOLDER_ID = 'abcXYZ'
# For serving download directory with ngrok's built-in file server
NGROK_AUTH_TOKEN = ""
# For clearing tasks whose upload is completed
AUTO_DEL_TASK = False
# For downloading files from uptobox
UPTOBOX_TOKEN = ""
# For sending files to log channel
LOG_CHANNEL = ""
# For sending files to you
BOT_PM = True
# Create worker using https://gitlab.com/GoogleDriveIndex/Google-Drive-Index
# Example: https://index.workers.dev/0: (Add drive index num with : at the end)
INDEX_LINK = ""

Build and run the docker image

docker build -t mybot:latest .

docker run -d --name=Mirror2GdriveBot \
  -e CONFIG_FILE_URL="github gist link of config.env" \
  --restart=unless-stopped \
  -v $PWD:/usr/src/app `#optional: for data persistence` \
  -p 8010:8090 -p 8020:6800 `#optional: for accessing qbit/aria` \
  mybot:latest

Extras

  • To generate token.pickle file. First place the credentials.json file in current directory and run.
docker run --rm -it -v $PWD:/mnt --net host --entrypoint python mybot:latest generate_token_pickle.py
  • To get the user session string of your bot.
docker run --rm -it --entrypoint python mybot:latest session_generator.py

Credits

mirror2gdrive's People

Contributors

sachin0raon avatar sachinoraon avatar rinrinx avatar

Stargazers

Yamraaj Yaduvanshi  avatar Arbaz Khan avatar  avatar mikey3 avatar emtee40 avatar  avatar sanket karowa avatar  avatar vonDubenshire avatar NextGenOP avatar  avatar Denis Travis avatar LoneDeveloper avatar AbHiShEk avatar  avatar Peter Kure avatar Amirul Islam avatar yuandx123 avatar nb avatar  avatar CHNOPS avatar NOISE avatar  avatar Unagi avatar Karan Soren avatar Sito Mao aka Eric Austin avatar Brainded Kazuma avatar  avatar M.Furkan avatar Hank Blaze avatar Mohamed Ks avatar Muhammed Asraf avatar Abhishek. avatar  avatar Usman Mughal avatar Ruban Durai avatar Sooraj avatar Dr.Caduceus avatar  avatar Nikhil avatar

Watchers

Kostas Georgiou avatar VXM avatar  avatar  avatar

mirror2gdrive's Issues

Change Command Name

start - ๐Ÿ‘ฝ Start the bot
mirror - ๐Ÿ—ณ Mirror file using Aria2
qbmirror - ๐Ÿงฒ Mirror file using Qbittorrent
unzipmirror - ๐Ÿ—ƒ๏ธ Mirror & unzip using Aria2
qbunzipmirror - ๐Ÿซง Mirror & unzip using Qbittorrent
status - ๐Ÿ“ฅ Show the task
ngrok - ๐ŸŒ Show Ngrok URL
stats - โš™๏ธ Show system info
log - ๐Ÿ“„ Get runtime log file

This link does not download and the bot freezes

Screenshot_1

magnet:?xt=urn:btih:2e766a9877ebfcddb003f3768c6ecaab8c3878bc&dn=Splice.2009.1080p.BluRay.REMUX.AVC.DTS-HD.MA.5.1-TURG.mkv&tr=http%3a%2f%2ftrack2.plux.me%3a2710%2f2969249a83b7b0414ba9614af471dbcb%2fannounce

Features and Error

Reply file and link upload .torrent file /aria and /qbit

main - ERROR - Failed to answer callback for: qbit-file#2f18e72afa7d3b9fa1440239fdc78d05825ec29a

if the file is wrong, it is not canceled, can you solve this too?

Files

The files should be deleted after the upload is successfully uploaded to gdrive or telegram, to free up storage,

Log channel Feature

If there is a LOG CHANNEL, the files that can be added are sent to the log channel after they are downloaded, which would be a good feature.

it can be added as two options either send pm only or send only to daily channel or send to both

LOG_CHANNEL = "channelid"
BOT_PM = "True"

In this way, the bot will send a message to both the channel and the bot.

LOG_CHANNEL = "channelid"
BOT_PM = "False"

In this way, the bot will only send files to the channel.

Status

Hi , thank you for this great project.
But the UI is a bit weird , can you make it easy like those mirror bots available, and support for index link , if it's possible

Upload files Media or Doc

Add the /usettings command, add a setting to upload the file as doc or media

With an additional command, a setting such as upload doc or select media should be added as a button.

Auto Delete Status

you will use the variable so that the status is automatically cleared after uploading

False or True

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.