diff --git a/beetsplug/mpdupdate.py b/beetsplug/mpdupdate.py index 8ea1b5204..6c39375be 100644 --- a/beetsplug/mpdupdate.py +++ b/beetsplug/mpdupdate.py @@ -68,7 +68,7 @@ class MPDUpdatePlugin(BeetsPlugin): def __init__(self): super(MPDUpdatePlugin, self).__init__() config['mpd'].add({ - 'host': u'localhost', + 'host': os.environ.get('MPD_HOST', u'localhost'), 'port': 6600, 'password': u'', }) diff --git a/docs/plugins/mpdupdate.rst b/docs/plugins/mpdupdate.rst index 954a87b33..c846b917f 100644 --- a/docs/plugins/mpdupdate.rst +++ b/docs/plugins/mpdupdate.rst @@ -31,7 +31,7 @@ Configuration The available options under the ``mpd:`` section are: - **host**: The MPD server name. - Default: ``localhost``. + Default: The ``$MPD_HOST`` environment variable if set, falling back to ``localhost`` otherwise. - **port**: The MPD server port. Default: 6600. - **password**: The MPD server password.