Giter VIP home page Giter VIP logo

ansible-role-mpd's Introduction

Ansible Role: mpd

An Ansible role that installs MPD (Music Player Daemon) on Fedora.

Requirements

The UnitedRPMs or rpmfusion-free repository has to be installed before running this role.

For configuring the firewall the service firewalld has to run and the package python-firewall needs to be installed.

Role Variables

Available variables are listed below, along with default values:

mpd_outputs:
  - name: "Null Output"
    type: "null"

mpd_name: Music Player Daemon
mpd_restore_paused: yes
mpd_auto_update: yes
mpd_follow_inside_symlinks: yes
mpd_follow_outside_symlinks: no

mpd_music_directory: /var/lib/mpd/music
mpd_playlist_directory: /var/lib/mpd/playlists

mpd_db_file: /var/lib/mpd/mpd.db
mpd_sticker_file: /var/lib/mpd/sticker.db
mpd_state_file: /var/lib/mpd/mpdstate

mpd_user: mpd
mpd_autostart: false

mpd_bind_to_address: any
mpd_firewall_zones: []

Outputs

The outputs for MPD can be configured with the variable mpd_outputs. The properties of an output are written as is into the configuration file. See Configuring audio outputs and Output plugins for more details.

Configuration

There are some variables to configure the behaviour of MPD like mpd_auto_update, mpd_name and more, see above for a complete list.

Directories

If you want to store your music and playlists in directories other than the default ones, change the variables mpd_music_directory and mpd_playlist_directory accordingly. Those directories won't be created, so make sure they exist and have correct permissions set.

Files

With the variables mpd_db_file, mpd_sticker_file and mpd_state_file the paths to those files can be changed.

User

The variable mpd_user can be used to change the user which runs MPD. The group will also be set to this value.

Autostart

Usually MPD will be activated using a systemd socket, so that it doesn't have to run permanetly. You can set mpd_autostart to yes to always start MPD on boot.

Networking

If you want that MPD only binds to a single interface, you can set that in the variable mpd_bind_to_address.

The variable mpd_firewall_zones can be used to declare firewall zones in which kodi should be accessible. This means the port 6600/tcp will be opened.

Currently only firewalld is supported which is default on Fedora.

Dependencies

None

Example Playbook

- hosts: all
  roles:
    - { role: mjanser.mpd }

License

MIT

ansible-role-mpd's People

Contributors

mjanser avatar

Watchers

 avatar  avatar

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.