Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

Switch to yt-dlp #388

Open
inyourface34456 opened this issue Jan 25, 2022 · 7 comments
Open

Switch to yt-dlp #388

inyourface34456 opened this issue Jan 25, 2022 · 7 comments
Labels

Comments

@inyourface34456
Copy link

New Feature Request

Can you do a full switch to yt-dlp? This could make downloading much faster in general, and also while you are at it, add the flag --compat-options no-playlist-metafiles and (once you complete the conversion) -N 20? That would make things a lot easier on me because then i do not have to go and add all of the metadata myself.

@Rudloff
Copy link
Owner

Rudloff commented Jan 25, 2022

This can be configured in your config file (see this example).
You can set youtubedl to point to your yt-dlp install and you can use params to set any option you need.

@inyourface34456
Copy link
Author

How would I do this in replit.com? How would i even make this compatible (it throws an error when I try to run it, to run it you have to type php -S 0.0.0.0:8000 -f index.php in the shell tab)?

@AyoKeito
Copy link

AyoKeito commented Jan 27, 2022

It's easy for installation from Github sources.
Assuming you have python3 and the alltube itself installed and working:

Git clone yt-dlp to /vendor subfolder of alltube
Edit config/config.yml:
Change:
youtubedl: vendor/ytdl-org/youtube-dl/youtube_dl/__main__.py
to:
youtubedl: vendor/yt-dlp/yt_dlp/__main__.py

Change:
python: /usr/bin/python
to:
python: /usr/bin/python3

That's enough to make it work.
As for other flags you want, i have no idea, never tried them.

@gramakri
Copy link

You can also download the yt-dlp binary separately and update the config like so:

# Path to your youtube-dl binary
youtubedl: /usr/local/bin/yt-dlp

# Path to your python binary
python: /usr/bin/python3

@inyourface34456
Copy link
Author

inyourface34456 commented Jan 31, 2022

When I ran it, the first error that it yelled at me about was not having something called autoload.php. I do not know what that is or how to get it, since i just tossed all of the files in to replit.com and ran it. This is why I haven't figured it out already.
Screenshot:
image

@rafalohaki
Copy link

rafalohaki commented Mar 27, 2022

here is edited by me yt-dlp version for heroku if u want
https://github.com/rafalohaki/alltube

@Roman2K
Copy link

Roman2K commented Jun 6, 2022

Got it working on master with very minor changes to the Dockerfile:

diff --git a/Dockerfile b/Dockerfile
index e5ac935..d2f7124 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,6 +1,7 @@
 FROM php:7.3-apache
 RUN apt-get update
-RUN apt-get install -y libicu-dev xz-utils git python libgmp-dev unzip ffmpeg
+RUN apt-get install -y libicu-dev xz-utils git python3 python3-pip libgmp-dev unzip ffmpeg
+RUN python3 -m pip install yt-dlp
 RUN docker-php-ext-install mbstring
 RUN docker-php-ext-install intl
 RUN docker-php-ext-install gmp

And these 2 entries in config.yml:

youtubedl: /usr/local/bin/yt-dlp
python: /usr/bin/python3

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

6 participants