this post was submitted on 09 Sep 2025
23 points (92.6% liked)

Selfhosted

53360 readers
174 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

  7. No low-effort posts. This is subjective and will largely be determined by the community member reports.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 2 years ago
MODERATORS
 

I've had this concept in my head for a while, I'm kind of amazed it doesn't exist yet.

I want to send a link to a music track to an app on my server, probably yt, maybe Spotify, and have that track be archived on my server, with the metadata from the service, preferably in a place Jellyfin can get at it.

There's a few ways to do that with YT playlist links, but not with adhoc requests for individual tracks, as far as I can see.

Is this not something that exists? I'm thinking it might not be too hard to write, if it doesn't.

top 11 comments
sorted by: hot top controversial new old
[–] Chaser@lemmy.zip 11 points 2 months ago (2 children)

yt-dlp can handle YouTube Music Links. Just tell it with -x --audio-format mp3, that you don't want the Video, but an mp3 (opus can't be tagged). I use it to obtail whole artists, then I tag them with MusicBrainz Picard. I'm sure there is a way to automate this. yt-dlp has also a Python library. However I haven't used it for now.

[–] tal@lemmy.today 16 points 2 months ago* (last edited 2 months ago) (1 children)

opus can’t be tagged

I'm pretty sure that it supports tagging.

goes to try it out

$ yt-dlp -x https://www.youtube.com/shorts/syF8M3aeiWs >/dev/null
$ opustags beep\ sound\ effect\ \[syF8M3aeiWs\].opus |grep -v ^METADATA
language=eng
encoder=Lavf61.7.100
title=beep sound effect
date=20230316
purl=https://www.youtube.com/watch?v=syF8M3aeiWs
synopsis=beep
DESCRIPTION=https://www.youtube.com/watch?v=syF8M3aeiWs
artist=Seth's old channel 
$

If you mean that this MusicBrainz Picard thing doesn't support tagging Opus, it sounds like it does:

https://community.metabrainz.org/t/musicbrainz-picard-doesnt-support-opus-files/467209

I have been having trouble tagging .opus files. Every time I try to edit .opus files I get:

(error: read b'\x1aE\xdf\xa3', expected b'OggS', at 0x0)

Looks like this is not a valid Ogg Opus file. Opus is just an audio codec, not a file format. Files with the file extension .opus are supposed to be inside an Ogg container, and that’s what Picard supports.

Your’s seems to be a Matroska file, and Picard does not support Matroska files yet.

And looking at the output of yt-dlp -x, it looks like it's Opus in an Ogg container:

$ file beep\ sound\ effect\ \[syF8M3aeiWs\].opus
beep sound effect [syF8M3aeiWs].opus: Ogg data, Opus audio, version 0.1, stereo, 48000 Hz (Input Sample Rate)
$

EDIT: Note that my ~/.config/yt-dlp/config file is:

--embed-subs
--write-auto-subs
--embed-metadata
--embed-chapters
--embed-thumbnail
--sponsorblock-mark=all

It may be that one needs --embed-metadata on the yt-dlp command-line if one isn't setting it in their yt-dlp config file to get the above tags; it might be that none normally get set.

[–] Chaser@lemmy.zip 4 points 2 months ago (1 children)

Awesome! I just learned something today. Thanks for pointing it out so detailed!

[–] source_of_truth@lemmy.world 1 points 2 months ago

If I want to just download the audio, I use eg:

yt-dlp -f 251 -o '%(title)s [%(id)s] f%(format_id)s.ogg' https://www.youtube.com/watch/?v%5C=fuHrtqx52J4
[–] Arghblarg@lemmy.ca 4 points 2 months ago (1 children)

An absolutely ancient tool I used to use was WinAmp (v2.x) with the Streamripper plugin. It would save out each song from a shoutcast or icecast station to a file with the artist/album/title/track like a champ. Maybe not quite what you want (won't do youtube) but there are a ton of great indie stations on the vorbis icecast network...

[–] Chaser@lemmy.zip 1 points 2 months ago (1 children)

That's a cool approach! Reminds me of the old Napster 🤓

[–] Arghblarg@lemmy.ca 1 points 2 months ago

Search for v2.79 (if memory serves) on oldversion.com for the last 'good' version of classic winamp, and the streamripper plugin is still floating around somewhere on the 'net....

[–] Antagnostic@lemmy.world 5 points 2 months ago* (last edited 2 months ago)

Somewhat related to spotify-downloader, which takes a yt or spotify link, playlist or singular it figures it out, and retrieves the listed songs from youtube (utilizing yt-dlp libraries). This is similar and adjacent to the other tools linked in this thread.

[–] carloshr@lile.cl 3 points 2 months ago

I don't totally understand your request. Maybe, do you refer to something like https://odesli.co/ that can generate a kind of "universarl url" for songs in streaming services. isn't it?

@bruhbeans @selfhosted

[–] bruhbeans@lemmy.ml 3 points 2 months ago

https://github.com/alexta69/metube

This is doing enough of what I wanted for now....

[–] onslaught545@lemmy.zip 1 points 2 months ago

You can mark single tracks in Lidarr if you want to go the Usenet/torrent route.