Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen der Seite angezeigt.
| Beide Seiten, vorherige Überarbeitung Vorherige Überarbeitung Nächste Überarbeitung | Vorherige Überarbeitung | ||
| doku:musik [13.06.2017 19:32] – starcalc | doku:musik [05.08.2022 22:51] (aktuell) – Externe Bearbeitung 127.0.0.1 | ||
|---|---|---|---|
| Zeile 2: | Zeile 2: | ||
| Für die Musik läuft ein MPD auf einem Raspberry PI 3 | Für die Musik läuft ein MPD auf einem Raspberry PI 3 | ||
| - | |||
| - | Hostname rpi3.raum.ctdo.de | ||
| - | User: pi | ||
| - | Pass: wasserfall | ||
| - | |||
| - | Per ssh einloggen und " | ||
| Musik per Webbrowser steuern: http:// | Musik per Webbrowser steuern: http:// | ||
| Die Quellenwahl und Lautstärke kann durch das Projekt [[projekte: | Die Quellenwahl und Lautstärke kann durch das Projekt [[projekte: | ||
| - | |||
| - | |||
| - | |||
| - | |||
| - | === Konfiguration auf dem Raspberry Pi === | ||
| - | |||
| - | ==== / | ||
| - | < | ||
| - | #!/bin/sh -e | ||
| - | # | ||
| - | # rc.local | ||
| - | # | ||
| - | # This script is executed at the end of each multiuser runlevel. | ||
| - | # Make sure that the script will "exit 0" on success or any other | ||
| - | # value on error. | ||
| - | # | ||
| - | # In order to enable or disable this script just change the execution | ||
| - | # bits. | ||
| - | |||
| - | # Activate iptables firewall: Only access from CTDO-IP-Range | ||
| - | iptables -F INPUT | ||
| - | iptables -P INPUT DROP | ||
| - | iptables -A INPUT -m conntrack --ctstate ESTABLISHED, | ||
| - | iptables -A INPUT -p icmp -j ACCEPT | ||
| - | iptables -A INPUT -i lo -m conntrack --ctstate NEW -j ACCEPT | ||
| - | iptables -A INPUT -s 195.160.168.0/ | ||
| - | iptables -A INPUT -j REJECT | ||
| - | |||
| - | # Activate ip6tables firewall: Only access from CTDO-IP-Range (IPv6) | ||
| - | ip6tables -F INPUT | ||
| - | ip6tables -P INPUT DROP | ||
| - | ip6tables -A INPUT -m conntrack --ctstate ESTABLISHED, | ||
| - | ip6tables -A INPUT -p icmpv6 -j ACCEPT | ||
| - | ip6tables -A INPUT -i lo -m conntrack --ctstate NEW -j ACCEPT | ||
| - | ip6tables -A INPUT -s fe80::/ | ||
| - | ip6tables -A INPUT -j REJECT | ||
| - | |||
| - | # Make sure that volume is UP when rpi has booted | ||
| - | amixer set Master 100% | ||
| - | |||
| - | # Do NOT play anything after reboot. (Don't freak out the one who just gave power to the room) | ||
| - | mpc pause | ||
| - | |||
| - | # Bridge script to give information about current file to MQTT. | ||
| - | / | ||
| - | |||
| - | exit 0 | ||
| - | </ | ||
| - | |||
| - | ==== / | ||
| - | < | ||
| - | music_directory "/ | ||
| - | playlist_directory "/ | ||
| - | db_file "/ | ||
| - | log_file "/ | ||
| - | pid_file "/ | ||
| - | state_file "/ | ||
| - | sticker_file | ||
| - | user " | ||
| - | bind_to_address | ||
| - | bind_to_address | ||
| - | bind_to_address | ||
| - | bind_to_address | ||
| - | zeroconf_enabled " | ||
| - | zeroconf_name " | ||
| - | input { | ||
| - | plugin " | ||
| - | } | ||
| - | audio_output { | ||
| - | type " | ||
| - | name " | ||
| - | format " | ||
| - | # | ||
| - | mixer_control " | ||
| - | } | ||
| - | filesystem_charset " | ||
| - | id3v1_encoding " | ||
| - | </ | ||
| - | |||
| - | ==== / | ||
| - | < | ||
| - | music_directory "/ | ||
| - | playlist_directory "/ | ||
| - | db_file "/ | ||
| - | log_file "/ | ||
| - | pid_file "/ | ||
| - | state_file "/ | ||
| - | sticker_file | ||
| - | user " | ||
| - | bind_to_address | ||
| - | bind_to_address | ||
| - | bind_to_address | ||
| - | bind_to_address | ||
| - | zeroconf_enabled " | ||
| - | zeroconf_name " | ||
| - | input { | ||
| - | plugin " | ||
| - | } | ||
| - | audio_output { | ||
| - | type " | ||
| - | name " | ||
| - | format " | ||
| - | # | ||
| - | mixer_control " | ||
| - | } | ||
| - | filesystem_charset " | ||
| - | id3v1_encoding " | ||
| - | </ | ||
| - | |||
| - | ==== /etc/fstab ==== | ||
| - | Die ersten drei Einträge sollten bereits vorhanden sein, es wird nur der zusätzliche Link auf die Filebase benötigt. Mit < | ||
| - | < | ||
| - | proc /proc | ||
| - | / | ||
| - | / | ||
| - | # filebase.raum.chaostreff-dortmund.de/ | ||
| - | // | ||
| - | </ | ||