[DOCKER] Daapd (Itunes) -Server


Recommended Posts

DEPRECATED, USE THIS VERSION

http://lime-technology.com/forum/index.php?topic=44210.0

 

beta first release of Daapd-Server, itunes server type thing.

 

map /music to your music collection (it's read only mapping by default, so don't panic) and it will appear in itunes.

 

tested on OSX 10.10.4 (yosemite) with itunes 12.2.0.145 (latest version at time of posting)

 

find it in my beta repo.

 

nicked gfjardim's disable dbus sed line and linking to unraid's dbus to get avahi working... thanks for that...

Link to comment

Sparkly, is this would be working  :D :D :D

 

This is what I see in my log:

*** Running /etc/my_init.d/001-bring-up-the-app.sh...
2015-07-09 14:05:21,263 CRIT Supervisor running as root (no user in config file)
2015-07-09 14:05:21,265 INFO supervisord started with pid 5
2015-07-09 14:05:22,267 INFO spawned: 'daapd-server' with pid 10
2015-07-09 14:05:22,575 INFO exited: daapd-server (exit status 0; not expected)
2015-07-09 14:05:23,576 INFO spawned: 'daapd-server' with pid 12
2015-07-09 14:05:23,595 INFO exited: daapd-server (exit status 0; not expected)
2015-07-09 14:05:25,597 INFO spawned: 'daapd-server' with pid 14
2015-07-09 14:05:25,614 INFO exited: daapd-server (exit status 0; not expected)
2015-07-09 14:05:28,618 INFO spawned: 'daapd-server' with pid 21
2015-07-09 14:05:28,627 INFO exited: daapd-server (exit status 0; not expected)
2015-07-09 14:05:29,628 INFO gave up: daapd-server entered FATAL state, too many start retries too quickly
*** An error occurred. Aborting.

Jul 9 14:07:25 Tower kernel: device veth1bad63e left promiscuous mode
Jul 9 14:07:25 Tower kernel: docker0: port 3(veth1bad63e) entered disabled state
Jul 9 14:07:30 Tower sshd[29429]: Accepted password for root from 192.168.178.30 port 53767 ssh2
Jul 9 14:09:45 Tower php: /usr/bin/docker start Daapd-Server
Jul 9 14:09:45 Tower kernel: device veth89cfa48 entered promiscuous mode
Jul 9 14:09:45 Tower avahi-daemon[9556]: Withdrawing workstation service for veth06944f2.
Jul 9 14:09:45 Tower kernel: eth0: renamed from veth06944f2
Jul 9 14:09:45 Tower kernel: docker0: port 3(veth89cfa48) entered forwarding state
Jul 9 14:09:45 Tower kernel: docker0: port 3(veth89cfa48) entered forwarding state
Jul 9 14:09:45 Tower php: Daapd-Server
Jul 9 14:09:50 Tower emhttp: /usr/bin/docker logs --tail=350 -f Daapd-Server 2>&1
Jul 9 14:10:00 Tower kernel: docker0: port 3(veth89cfa48) entered forwarding state
Jul 9 14:14:08 Tower php: /usr/bin/docker restart Daapd-Server
Jul 9 14:14:08 Tower kernel: docker0: port 3(veth89cfa48) entered disabled state
Jul 9 14:14:08 Tower kernel: device veth89cfa48 left promiscuous mode
Jul 9 14:14:08 Tower kernel: docker0: port 3(veth89cfa48) entered disabled state
Jul 9 14:14:08 Tower avahi-daemon[9556]: Withdrawing workstation service for veth89cfa48.
Jul 9 14:14:08 Tower kernel: device vethfeaa3e9 entered promiscuous mode
Jul 9 14:14:08 Tower kernel: docker0: port 3(vethfeaa3e9) entered forwarding state
Jul 9 14:14:08 Tower kernel: docker0: port 3(vethfeaa3e9) entered forwarding state
Jul 9 14:14:08 Tower avahi-daemon[9556]: Withdrawing workstation service for veth0ea96fc.
Jul 9 14:14:08 Tower kernel: eth0: renamed from veth0ea96fc
Jul 9 14:14:08 Tower php: Daapd-Server
Jul 9 14:14:18 Tower emhttp: /usr/bin/docker logs --tail=350 -f Daapd-Server 2>&1
Jul 9 14:14:23 Tower kernel: docker0: port 3(vethfeaa3e9) entered forwarding state
Jul 9 14:16:28 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1
Jul 9 14:16:54 Tower php: /usr/bin/docker stop Daapd-Server
Jul 9 14:16:55 Tower php: Daapd-Server
Jul 9 14:16:55 Tower kernel: docker0: port 3(vethfeaa3e9) entered disabled state
Jul 9 14:16:55 Tower avahi-daemon[9556]: Withdrawing workstation service for vethfeaa3e9.
Jul 9 14:16:55 Tower kernel: device vethfeaa3e9 left promiscuous mode
Jul 9 14:16:55 Tower kernel: docker0: port 3(vethfeaa3e9) entered disabled state
Jul 9 14:16:58 Tower php: /usr/bin/docker start Daapd-Server
Jul 9 14:16:58 Tower kernel: device veth0ca8f96 entered promiscuous mode
Jul 9 14:16:58 Tower avahi-daemon[9556]: Withdrawing workstation service for vethfec2a18.
Jul 9 14:16:58 Tower kernel: eth0: renamed from vethfec2a18
Jul 9 14:16:58 Tower php: Daapd-Server
Jul 9 14:16:58 Tower kernel: docker0: port 3(veth0ca8f96) entered forwarding state
Jul 9 14:16:58 Tower kernel: docker0: port 3(veth0ca8f96) entered forwarding state
Jul 9 14:17:11 Tower emhttp: /usr/bin/docker logs --tail=350 -f Daapd-Server 2>&1
Jul 9 14:17:13 Tower kernel: docker0: port 3(veth0ca8f96) entered forwarding state
Jul 9 14:17:32 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1

 

Any advise? Thanks a lot for all your Docker activities!!!

Link to comment
root@Tower:~# docker exec  Daapd-Server cat  /var/log/forked-daapd.log
[2015-07-09 14:42:37] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:42:37] [  LOG]     main: mDNS init
[2015-07-09 14:42:37] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:42:37] [  LOG]       db: Now vacuuming database, this may take some time...
[2015-07-09 14:42:38] [  LOG]       db: Database OK with 2475 active files and 6 active playlists
[2015-07-09 14:42:38] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:42:38] [  LOG]     main: mDNS init
[2015-07-09 14:42:38] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:42:38] [  LOG]       db: Could not check database version, trying DB init
[2015-07-09 14:42:38] [FATAL]       db: DB init error: database is locked
[2015-07-09 14:42:38] [FATAL]       db: Could not create tables
[2015-07-09 14:42:38] [FATAL]     main: Database init failed
[2015-07-09 14:42:38] [  LOG]     main: mDNS deinit
[2015-07-09 14:42:38] [  LOG]     main: Exiting.
[2015-07-09 14:42:40] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:42:40] [  LOG]     main: mDNS init
[2015-07-09 14:42:40] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:42:40] [  LOG]       db: Now vacuuming database, this may take some time...
[2015-07-09 14:42:41] [  LOG]       db: Database OK with 2475 active files and 6 active playlists
[2015-07-09 14:42:43] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:42:43] [  LOG]     main: mDNS init
[2015-07-09 14:42:43] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:42:43] [  LOG]       db: Now vacuuming database, this may take some time...
[2015-07-09 14:42:44] [  LOG]       db: Database OK with 2475 active files and 6 active playlists

Link to comment

I changed the last mapping: /var/cache/forked-daapd -->> /mnt/cache/.Docker/appdata/Daapd so basically the same share as the /config.

Log is looking different now:

root@Tower:/mnt/cache/.Docker/appdata/Daapd# docker exec  Daapd-Server cat  /var/log/forked-daapd.log
[2015-07-09 14:51:27] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:27] [  LOG]     main: mDNS init
[2015-07-09 14:51:27] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:27] [  LOG]       db: Could not check database version, trying DB init
[2015-07-09 14:51:28] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:28] [  LOG]     main: mDNS init
[2015-07-09 14:51:28] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:28] [  LOG]       db: Could not check database version, trying DB init
[2015-07-09 14:51:28] [FATAL]       db: DB init error: database is locked
[2015-07-09 14:51:28] [FATAL]       db: Could not create tables
[2015-07-09 14:51:28] [FATAL]     main: Database init failed
[2015-07-09 14:51:28] [  LOG]     main: mDNS deinit
[2015-07-09 14:51:28] [  LOG]     main: Exiting.
[2015-07-09 14:51:30] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:30] [  LOG]     main: mDNS init
[2015-07-09 14:51:30] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:30] [  LOG]       db: Could not check database version, trying DB init
[2015-07-09 14:51:30] [FATAL]       db: DB init error: database is locked
[2015-07-09 14:51:30] [FATAL]       db: Could not create tables
[2015-07-09 14:51:30] [FATAL]     main: Database init failed
[2015-07-09 14:51:30] [  LOG]     main: mDNS deinit
[2015-07-09 14:51:30] [  LOG]     main: Exiting.
[2015-07-09 14:51:31] [  LOG]       db: Database OK with 0 active files and 6 active playlists
[2015-07-09 14:51:33] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:33] [  LOG]     main: mDNS init
[2015-07-09 14:51:33] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:33] [  LOG]       db: Now vacuuming database, this may take some time...
[2015-07-09 14:51:33] [  LOG]       db: Could not VACUUM database: database is locked
[2015-07-09 14:51:33] [FATAL]       db: Database version check errored out, incompatible database
[2015-07-09 14:51:33] [FATAL]     main: Database init failed
[2015-07-09 14:51:33] [  LOG]     main: mDNS deinit
[2015-07-09 14:51:33] [  LOG]     main: Exiting.
[2015-07-09 14:51:52] [  LOG]     scan: Scanned 200 files...
[2015-07-09 14:51:57] [  LOG]     scan: Scanned 400 files...
[2015-07-09 14:52:07] [  LOG]     scan: Scanned 600 files...
[2015-07-09 14:52:14] [  LOG]     scan: Scanned 800 files...
[2015-07-09 14:52:22] [  LOG]     scan: Scanned 1000 files...
[2015-07-09 14:52:29] [  LOG]     scan: Scanned 1200 files...
[2015-07-09 14:52:37] [  LOG]     scan: Scanned 1400 files...
[2015-07-09 14:52:47] [  LOG]     scan: Scanned 1600 files...
[2015-07-09 14:52:56] [  LOG]     scan: Scanned 1800 files...
[2015-07-09 14:53:07] [  LOG]     scan: Scanned 2000 files...
[2015-07-09 14:53:13] [  LOG]     scan: Scanned 2200 files...
[2015-07-09 14:53:19] [  LOG]     scan: Scanned 2400 files...
[2015-07-09 14:53:25] [  LOG]     scan: Scanned 2600 files...
[2015-07-09 14:53:31] [  LOG]     scan: Scanned 2800 files...
[2015-07-09 14:53:38] [  LOG]     scan: Scanned 3000 files...

 

Still scanning but UNRAID-MUSIC is showing up now  :D :D :D :D :D

 

Thanks a lot Sparkly!!!

Link to comment

I changed the last mapping: /var/cache/forked-daapd -->> /mnt/cache/.Docker/appdata/Daapd so basically the same share as the /config.

Log is looking different now:

root@Tower:/mnt/cache/.Docker/appdata/Daapd# docker exec  Daapd-Server cat  /var/log/forked-daapd.log
[2015-07-09 14:51:27] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:27] [  LOG]     main: mDNS init
[2015-07-09 14:51:27] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:27] [  LOG]       db: Could not check database version, trying DB init
[2015-07-09 14:51:28] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:28] [  LOG]     main: mDNS init
[2015-07-09 14:51:28] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:28] [  LOG]       db: Could not check database version, trying DB init
[2015-07-09 14:51:28] [FATAL]       db: DB init error: database is locked
[2015-07-09 14:51:28] [FATAL]       db: Could not create tables
[2015-07-09 14:51:28] [FATAL]     main: Database init failed
[2015-07-09 14:51:28] [  LOG]     main: mDNS deinit
[2015-07-09 14:51:28] [  LOG]     main: Exiting.
[2015-07-09 14:51:30] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:30] [  LOG]     main: mDNS init
[2015-07-09 14:51:30] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:30] [  LOG]       db: Could not check database version, trying DB init
[2015-07-09 14:51:30] [FATAL]       db: DB init error: database is locked
[2015-07-09 14:51:30] [FATAL]       db: Could not create tables
[2015-07-09 14:51:30] [FATAL]     main: Database init failed
[2015-07-09 14:51:30] [  LOG]     main: mDNS deinit
[2015-07-09 14:51:30] [  LOG]     main: Exiting.
[2015-07-09 14:51:31] [  LOG]       db: Database OK with 0 active files and 6 active playlists
[2015-07-09 14:51:33] [  LOG]     main: Forked Media Server Version 23.2 taking off
[2015-07-09 14:51:33] [  LOG]     main: mDNS init
[2015-07-09 14:51:33] [  LOG]     mdns: Avahi state change: Client running
[2015-07-09 14:51:33] [  LOG]       db: Now vacuuming database, this may take some time...
[2015-07-09 14:51:33] [  LOG]       db: Could not VACUUM database: database is locked
[2015-07-09 14:51:33] [FATAL]       db: Database version check errored out, incompatible database
[2015-07-09 14:51:33] [FATAL]     main: Database init failed
[2015-07-09 14:51:33] [  LOG]     main: mDNS deinit
[2015-07-09 14:51:33] [  LOG]     main: Exiting.
[2015-07-09 14:51:52] [  LOG]     scan: Scanned 200 files...
[2015-07-09 14:51:57] [  LOG]     scan: Scanned 400 files...
[2015-07-09 14:52:07] [  LOG]     scan: Scanned 600 files...
[2015-07-09 14:52:14] [  LOG]     scan: Scanned 800 files...
[2015-07-09 14:52:22] [  LOG]     scan: Scanned 1000 files...
[2015-07-09 14:52:29] [  LOG]     scan: Scanned 1200 files...
[2015-07-09 14:52:37] [  LOG]     scan: Scanned 1400 files...
[2015-07-09 14:52:47] [  LOG]     scan: Scanned 1600 files...
[2015-07-09 14:52:56] [  LOG]     scan: Scanned 1800 files...
[2015-07-09 14:53:07] [  LOG]     scan: Scanned 2000 files...
[2015-07-09 14:53:13] [  LOG]     scan: Scanned 2200 files...
[2015-07-09 14:53:19] [  LOG]     scan: Scanned 2400 files...
[2015-07-09 14:53:25] [  LOG]     scan: Scanned 2600 files...
[2015-07-09 14:53:31] [  LOG]     scan: Scanned 2800 files...
[2015-07-09 14:53:38] [  LOG]     scan: Scanned 3000 files...

 

 

that's working now

Link to comment

if anyone works out how to use REMOTE.

Do you have all cover art? And is there any way to import the rating from an existing iTunes instance?

 

 

REMOTE is another config file i think, but the other things are probably in the config and require playing...

 

i'll take a look later, got life type shit to do, lol.

Link to comment

i think the artwork only works if there is a image file in the album folder...

 

i've changed a setting in the config file to pick up artwork if it starts with any of the following names

 

artwork_basenames = { "artwork", "cover", "Folder", "folder" }

 

to get the latest config file version go into your /config folder and delete the file called

 

forked-daapd.conf

 

and restart the container.....

 

also if you have a cache mapping already, you'll need to delete that too from the template and your local appdata as it is now in the /config folder.

 

it will mean rescanning your library..

 

i'm looking into the scanning of existing itunes libraries, looks like a configure option in the build stage and an additional -dev dependency.

Link to comment

Quick feedback Sparkly. Remote works great. Really easy to implement. For the audience: as soon as you have started to remote app you have to enter settings/add iTunes blabla...

 

The log (in my case /mnt/cache/.Docker/appdata/Daapd/logs-databases-and-cache/forked-daapd.log is showing:

[2015-07-10 09:19:48] [  LOG]   remote: Discovered remote 'iPhoneOW' (id 043502A2-B870-4FB4-8DA5-C9D195239CE9) at 192.168.178.52:58334, paircode A8ED9444A3B28D2D

 

Move a textile that consists of two lines (in my case iPhoneOW and the paircode, NOT the code shown above but the 4 digit code that the iPhone is showing) into the iTunes library. Done. Log should show something like:

[2015-07-10 09:27:21] [  LOG]   remote: Read Remote pairing data (name 'iPhoneOW', pin '6662') from /music/iPhoneOW.remote

 

Also coverart working great. I have a folder.jpg in every album directory that is now showing up.

 

Only issue with audio output (only via remote):

[2015-07-10 09:31:53] [  LOG]   raop: RECORD request failed in session startup: 0 (null)
[2015-07-10 09:31:53] [  LOG]   player: Cannot start playback: no output started
[2015-07-10 09:31:53] [  LOG]   dacp: Could not start playback

 

The window to select the output disappears too quick to be selected.

Link to comment

forked my own github for this and have rebuilt it replacing some of the dependencies with self compiled versions rather than ones in the apt repositories.

 

fixed the database issues and the main app starts up nicely now without reporting crashes and the db in general is more stable.

 

but the libav version either needs tweaking or replacing as i'm getting some errors there.

Link to comment
Guest
This topic is now closed to further replies.