This is the user-facing documentation for muzak's configuration.
For the developer documentation, see.
All of muzak's configuration is kept in
require) from ,
which is YAML-formatted.
Muzak loads configuration keys just like commands, translating them from
snake_case. For example, take the following configuration:
--- debug: true verbose: true music: "/home/william/mnt/fortuna/music/" player: mpv art-geometry: 300x300 jukebox-size: 100 deep-index: true
This is exposed in
Muzak::Config as follows:
::.debug # => true ::.verbose # => true ::.music # => "/home/william/mnt/fortuna/music/" ::.player # => "mpv" ::.art_geometry # => "300x300" ::.jukebox_size # => 100
muzak is loaded via
it can be used within both scripts and clients. As such, it should be preferred
over custom configuration solutions for external programs that interact
primarily with muzak.
resolves undefined keys to
false, allowing a pattern like
something_special Config.special_key if Config.special_key
A note on plugin configuration
Muzak loads a plugin if and only if
plugin-$name is present in the
$name is the lowercased class name of the plugin
(see and ).
For example, to enable the made-up "foo" plugin, your configuration should include something like this.
plugin-foo: foo-option-1: bar foo-option-2: baz
Plugins can, of course, access their configuration through:
::.plugin_foo["foo-option-1"] # => "bar"
These are the configuration keys observed by muzak's "core," particularlyany everything it controls.
In no particular order:
event: false is set in the configuration file, then muzak will not
attempt to propagate events to plugins. This might be useful for debugging
or when using multiple players at once via .
debug: true is set in the configuration file, then muzak operates in
debugging mode. This includes printing debug messages and not forking
into the background.
verbose: true is set in the configuration file, then muzak operates in
verbose mode. This includes printing informational messages and not forking
muzakd into the background.
music: <directory> should be set to the directory of the music library.
Muzak uses this key to point the indexer at the correct directory.
player: <player> should be set to the human-friendly name of the user's music
player. This human-friendly name is generated from the player's ruby class name
just like a plugin (e.g.,
Muzak uses this key to find the correct underclass to
initialize and control.
The short names of supported players can be found in.
mpv-no-art: true is set in the configuration file and
player: mpv is
mpv will be instructed to disable all video output entirely.
This option is primarily useful in conjunction with plugins that provide
album art display, or for making Muzak entirely non-graphical.
Mandatory if using
player key is set to
multiplayer, then this should be set to the
array of players to use together. For example,
multiplayer-players: [mpv, mpd].
mpd-host is set and the
mpd player is used, then
mpd will use this
value as the MPD host to connect to.
mpd-port is set and the
mpd player is used, then
mpd will use this
value as the MPD port to connect to.
jukebox-size: <size> should be set to the number of random songs to enqueue
by default with the
art-geometry: <geometry> should be set to the desired size of displayed
album art, in "WxH" format. If not set, album art will be displayed at
any size the player pleases.
It's entirely up to the user's player and/or plugins to obey this value.
autoplay: true is set in the configuration file, then muzak will begin
tell the player to begin playing as soon as media is loaded.
default_playlist: <playlist> should be set to a playlist that the user wishes
to automatically load when muzak starts. If not set, no playlist is
default_playlist does not automatically play the specified playlist
(it only loads it).
autoplay: true must be set to automatically play the
These are configuration keys observed by muzak's interface(s).
daemon-port: <port> should be set to a valid port number for
daemon-host: <hostname> should be set to the hostname for
dmenu-exec: <command args...> can be used to alter
dmenu. It can also be used to substitute a dmenu-compatible
dmenu-lines-exec: <command args> can be used to alter
dmenu when showing selections on multiple lines (e.g.,
when offering albums after
enqueue-album has been selected). It can be
used to substitute a dmenu-compatible prompt like