Jump to content

[Support] CATDUCK YTDL-Sub (YouTube Downloading with Meta Data for Plex/Kodi/JellyFin)


Recommended Posts

  • CatDuck changed the title to [Support] CATDUCK YTDL-Sub (YouTube Downloading with Meta Data for Plex/Kodi/JellyFin)
  • 1 month later...
20 minutes ago, Eurotimmy said:

Thank you @CatDuck for putting this up on CA!
I'll give this a try as I have recently failed to get TubeSync working adequately (also in CA)... my number of files to 'sync' was too large for the current TubeSync version to handle.
 

I think you will be really happy! I love the metadata showing in plex especially. Come in discord and say hello if you get it working (or have trouble)

Link to comment

Hey all, I have my training wheels on so please forgive if this is a pretty basic knowledge share.
I am impressed with ytdl-sub so far!

My issue...
Each time I ran ytdl-sub every folder / file created & each downloaded file was owned by 'root:root'.
I was connecting to the console of the container and running my commands, which of course is running as 'root'... kind of obvious error now looking back on it.

My learning was to run the ytdl-sub from the host console, after opening up a bash on the container as the 'abc' user.

Open up the "Terminal" from the icon in the Unraid header menu

Then, open the bash as user 'abc', run the command

docker exec -u abc -it ytdl-sub /bin/bash


Setup your config.yaml and subscriptions.yaml how ever you want it.

Then run ytdl-sub (use your own ytdl-sub command)

ytdl-sub --dry-run --config /config/config.yaml sub /config/subscriptions.yaml


This got the files and folders created / downloaded to the mapped locations on my server.
The user & group are now correctly set as 'nobody:users' like the rest of my media files in that location.

 

Also, to note...
The default config.yaml & subscriptions.yaml was setup & attempting to download a Rammstien music playlist which was failing.

Hope this helps somebody at the same remedial levels as me!! 🤗
 

Link to comment
  • 2 months later...
On 5/25/2023 at 12:55 PM, Eurotimmy said:

My learning was to run the ytdl-sub from the host console, after opening up a bash on the container as the 'abc' user.

 

That's pretty inconvenient though. Can I run as root or have a way to quickly execute the `ytdl-sub` command from the UI?

 

Also, it would be awesome if the cron job outputted some logs, which AFAICT it currently doesn't.

Link to comment

Hey @pranasziaukas, I should have elaborated after I made that learning to say I use the “User Scripts” in Unraid to automate the running of the YTDL-Sub container on my schedule.

 

I will post up a screenshot once I get home!!
 

BTW: I am loving YTDL-Sub and always enjoy seeing new episodes from the YT’ers I follow appearing in my media centre. 

 

Link to comment
  • 3 weeks later...

This tool is great, I've been able to set up automatic downloads on a schedule from various channels (and remove videos past a certain age). However, the remaining piece of functionality I cannot figure out is how to limit the resolution of a download to no more than 1080p.

 

I've tried, in the terminal:

"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml --format 'bestvideo[height<=1080]+bestaudio"

or
"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml -f bestvideo[height<=?1080]+bestaudio/best"

or

"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml -S "res:1080""

or

"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml -S res:1080"

 

In all cases either the quality qualifier seems to be ignored and I get a 4K file, or I get an error about the command being invalid.

 

Am I misguided in the way I am trying to apply the syntax?

 

Also, anyone know of a command to do the same that can be entered in the config.yaml file? I have not been able to identify such a command in the documentation.

 

Thanks!

Link to comment

Found the solution.

 

The property

---

ytdl_options:
          format: "FORMAT HERE"

---

can be set in the config file where FORMAT HERE is any format command that would otherwise work with ytdlp.

This particular ytdl_options field is not explicitly documented in the ytdl-sub documentation from what I can see.

Link to comment
19 minutes ago, Kiefer said:

This tool is great, I've been able to set up automatic downloads on a schedule from various channels (and remove videos past a certain age). However, the remaining piece of functionality I cannot figure out is how to limit the resolution of a download to no more than 1080p.

 

I've tried, in the terminal:

"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml --format 'bestvideo[height<=1080]+bestaudio"

or
"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml -f bestvideo[height<=?1080]+bestaudio/best"

or

"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml -S "res:1080""

or

"ytdl-sub --config /config/config.yaml sub /config/subscriptions.yaml -S res:1080"

 

In all cases either the quality qualifier seems to be ignored and I get a 4K file, or I get an error about the command being invalid.

 

Am I misguided in the way I am trying to apply the syntax?

 

Also, anyone know of a command to do the same that can be entered in the config.yaml file? I have not been able to identify such a command in the documentation.

 

Thanks!

 

Hello, you would want to add it to the config.yaml file. 

 

For example, I have in my config.yaml I have at the bottom:

 

  maxmp4:

   ytdl_options:

      format: "(bv*[ext=mp4][vcodec~='^((he|a)vc|h26[45])']+ba[ext=m4a]) / (bv[ext=mp4]*+ba[ext=m4a]/b)" 

 

I can then use the preset "maxmp4" to load this preset into any subscription, etc.

This will download in max quality MP4. This sometimes results in 4K MP4s, But that is rare and very short videos. This is for plex compatibility.  No AV1 in MP4.

 

You should also be able to do:

max1080p:

   ytdl_options:

      format: "(bv*[height<=1080]+bestaudio/best[height<=1080])"

 

This is per the yt-dlp docs. youtube-dl/README.md at master · ytdl-org/youtube-dl · GitHub

Link to comment
7 minutes ago, Kiefer said:

I was typing the solution for you at the same time we were replying. Guess I was not fast enough, :)

7 minutes ago, Kiefer said:

 

The property

---

ytdl_options:
          format: "FORMAT HERE"

---

can be set in the config file where FORMAT HERE is any format command that would otherwise work with ytdlp.

This particular ytdl_options field is not explicitly documented in the ytdl-sub documentation from what I can see.

 

Edited by CatDuck
Link to comment
  • 2 weeks later...
2 hours ago, unraid-user said:

What location have people chosen for their temp folder mapping?

My invocation of ytdl gives me a permission error on the temp folder when I run as abc user.

 

 

 

It's ok I have fixed that.  I'd set the temp folder in my media folder that didn't allow abc permissions.   Stuck it in a temp download area that other dockers also use and all is fine.

Link to comment
  • 1 month later...

Small update 

 

If you have the userscripts plugin (and don't want to mess around with cron) You can simply run:

 

docker exec -it ytdl-sub ytdl-sub sub -c /config/config.yaml  and set it to daily (or as needed)

 

Replace config.yaml with your path if its not in the default directory or multiple.

Link to comment
  • 5 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...