Git Product home page Git Product logo

mpd-scrobbler-docker's Introduction

mpd-scrobbler-docker

A Docker image for mpdscribble (Last.fm, Libre.fm and Jamendo scrobbler for mpd).

Reference

First and foremost, the reference to the awesome projects:

Music Player Daemon
MPDScribble

Links

Source: GitHub
Images: DockerHub

Why

I prepared this Dockerfile Because I wanted to be able to install mpdscribble easily on any machine (provided the architecture is amd64 or arm). Configuring the container is easy through a webapp like Portainer.

Prerequisites

You need to have Docker up and running on a Linux machine, and the current user must be allowed to run containers (this usually means that the current user belongs to the "docker" group).

You can verify whether your user belongs to the "docker" group with the following command:

getent group | grep docker

This command will output one line if the current user does belong to the "docker" group, otherwise there will be no output.

The Dockerfile and the included scripts have been tested on the following distros:

  • Manjaro Linux with Gnome (amd64)
  • Asus Tinkerboard
  • Raspberry Pi 3 and 4, both 32 and 64 bit

As I test the Dockerfile on more platforms, I will update this list.

Get the image

Here is the repository on DockerHub.

Getting the image from DockerHub is as simple as typing:

docker pull giof71/mpd-scrobbler

You may want to pull the "stable" image as opposed to the "latest".

Usage

You can start mpd-scrobbler by simply typing:

    docker run -d --rm \
        -e LASTFM_USERNAME=lastfmuser \
        -e LASTFM_PASSWORD=lastfmpassw \
        -e MPD_HOSTNAME=mpd-hostname \
        -e MPD_PORT=6600 \
        giof71/mpd-scrobbler

Environment Variables

The following tables reports all the currently supported environment variables.

VARIABLE NOTES
USER_MODE Enables user mode if set to YES
PUID Run using this User id. Defaults to 1000.
PGID Run using this Group id. Defaults to 1000.
MPD_HOST The host running MPD, possibly protected by a password([PASSWORD@]HOSTNAME). Defaults to localhost. Leave blank or localhost when running in network=host mode.
MPD_PORT The port that the MPD listens on and mpdscribble should try to connect to. Defaults to 6600, the default MPD port.
SCRIBBLE_VERBOSE How verbose mpdscribble's logging should be. Defaults to 1.
LASTFM_USERNAME Username for Last.fm
LASTFM_PASSWORD Password for Last.fm
LIBREFM_USERNAME Username for Libre.fm
LIBREFM_PASSWORD Password for Libre.fm
JAMENDO_USERNAME Username for Jamendo
JAMENDO_PASSWORD Password for Jamendo
PROXY
STARTUP_DELAY_SEC Delay before starting the application, defaults to 0

Volumes

Volume Description
/app/scribble/log Where mpdscribble will write its journals and its log file

Notable changes to the configuration

Changes to Environment Variables

A few environment variables have been deprecated, see the following table.

Deprecated Variable Deprecated Since Comment
USE_MPD_PASSWORD 2022-10-21 Removed variable: the MPD password must be specified with MPD_HOSTNAME if needed
USE_MPD_PASSWORD 2021-11-27 This variable is not required anymore: just set the MPD_PASSWORD variable

Changes to volumes

Date Description
2023-03-03 The log volume is now /app/scribble/log instead of app/scribble

Build

You can build (or rebuild) the image by opening a terminal from the root of the repository and issuing the following command:

docker build . -t giof71/mpd-scrobbler

It will take very little time even on a Raspberry Pi. When it's finished, you can run the container following the previous instructions.
Just be careful to use the tag you have just built.

Change History

Change Date Major Changes
2022-10-24 Support for daily builds
2022-10-24 Bugfix (wrong variable references and missing permissions)
2022-10-21 Run with unprivileged user
2022-10-21 Switch to mpdscribble

mpd-scrobbler-docker's People

Contributors

giof71 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

mpd-scrobbler-docker's Issues

Avoid the need to specify USE_MPD_PASSWORD

This environment variable should not be required. It should be enough for the user to specify the password in the "MPD_PASSWORD" variable.
Check if "MPD_PASSWORD" is not empty and then set the value in the mpdas.conf file accordingly.

[Feature] Let user configure where to log

It should be possible for the user to decide the destination of the log.
Add a variable named SCRIBBLE_LOG_DESTINATION with the possible values:

  • file
  • stdout
  • none

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.