Skip to content

TheWicklowWolf/PlaylistDir

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

61 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status Docker Pulls

logo

Make playlists from a directory of audio files.

Run using docker-compose

services:
  playlistdir:
    image: thewicklowwolf/playlistdir:latest
    container_name: playlistdir
    environment:
      - media_server_addresses=Plex:http://192.168.1.2:32400, Jellyfin:http://192.168.1.2:8096
      - media_server_tokens=Plex:x-token, Jellyfin:api-token
      - plex_library_section_id=0
      - path_to_parent=/path/to/parent
      - path_to_playlists=/path/to/playlists
      - sync_schedule=3
    ports:
      - 5000:5000
    volumes:
      - /path/to/parent:/playlistdir/parent:ro
      - /path/to/playlists:/playlistdir/playlists
      - /etc/localtime:/etc/localtime:ro
    restart: unless-stopped

Configuration via environment variables

Certain values can be set via environment variables:

  • PUID: The user ID to run the app with. Defaults to 1000.
  • PGID: The group ID to run the app with. Defaults to 1000.
  • media_server_addresses: Addresses for media servers, remove where not needed. Format: Plex:http://192.168.1.2:32400, Jellyfin:http://192.168.1.2:8096.
  • media_server_tokens: The API keys for media servers, remove where not needed. Format: Plex: abc, Jellyfin: xyz.
  • plex_library_section_id: Library section ID for Plex. Defaults to 0.
  • path_to_parent: Raw path to the parent directory. Defaults to .
  • path_to_playlists: Raw path to the playlists directory. Defaults to .
  • sync_schedule: Schedule hours to run. Defaults to
  • playlist_sorting_method: Sorting method, options are modified (sort by the modified timestamp of the files in decending order with latest files at the top, modified-ascending with latest files at the bottom) or alphabetically. Defaults to alphabetically.
  • include_subfolders: Include subfolders in search for music files. Defaults to False.

Sync Schedule

Use a comma-separated list of hours to start sync (e.g. 2, 20 will initiate a sync at 2 AM and 8 PM).

Note: There is a deadband of up to 10 minutes from the scheduled start time.

Example Folder Structure

/data/media/music/singles
├── playlists
│   ├── playlist1.m3u
│   ├── playlist2.m3u
│   └── ...
├── playlist1
│   ├── song_a.mp3
│   └── song_b.mp3
├── playlist2
│   ├── song_x.mp3
│   └── song_y.mp3
└── ...

Explanation

  • /data/media/music/singles: This is the parent directory containing your sub-folders. It is mapped to /playlistdir/parent in the container and should contain all your sub-folders.
    Set environmental variable: path_to_parent=/data/media/music/singles

  • /data/media/music/singles/playlists: This directory contains your playlist files. It is mapped to /playlistdir/playlists in the container and will contain all your .m3u playlist files.
    Set environmental variable: path_to_playlists=/data/media/music/singles/playlists


light


dark


https://hub.docker.com/r/thewicklowwolf/playlistdir

About

Convert a folder of music into a .m3u playlist.

Resources

License

Stars

Watchers

Forks

Contributors