Madsonic Docker container


Recommended Posts

@binhex - sounds like a doable solution. wasn't even thinking of it (guess - cause i had no real grip on docker at the point). but i might give it a spin just to see if this d*&$!* update time prob exists in your variation as well. :)

as for the 11tb - it took a while, but poss not as long as you think ;)

 

 

@pinion - since you run both binhex and botez madsonics already sidebyside - maybe you have some insights to share about differences you noticed???

 

cheers, L

Link to comment
  • Replies 98
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

I'm not sure if anything on either have changed in the past month or so and binhex has updated his to also use the latest madsonic beta so they're the same there. The main difference I see is botez is using the phusion base while binhex uses arch (I think) and https isn't setup in botez's so if you want that you'll need to use binhex's. Also, I never quite got binhex's working for transcoding FLAC so I haven't been using it. I was going to fork binhex's and add in https support but when I did I couldn't get his version to compile without error even without changes and then I got lazy.

 

Bottom line, if you need https go with binhex's work but you might not be able to transcode everything. If you don't care about https and you'd also like to keep a phusion base for all your dockers go with botez's. And make sure to thank them both for sharing their work with us :)

Link to comment
  • 2 weeks later...

binhex - Thanks for the work, looking to add this. I currently have a docker for usenet apps and want to separate docker image file for madsonic so the base repositories are separated.

 

Can someone help me how to create a second docker image and add this container to it?

 

Thanks!

 

quick update - have now updated docker to public release version of madsonic.

 

https://registry.hub.docker.com/u/binhex/arch-madsonic/

Link to comment

I installed the previous versi0n yesterday, how do I update to the latest version?

 

Delete the container and reinstall? Thank you for your work!

 

docker stop <container name>

docker rm <container name>

docker rmi binhex/arch-madsonic

 

then issue the docker run command again to pull down image and create container, do NOT delete anything in your specified config folder.

 

tip - once you have created the container using the run command you can then stop/restart/start the container using the short container name, you dont need to specify the run command each time.

Link to comment

binhex - Pulling the 1.5GB image took quite a while. Is the transcode update related to video only? I use madsonic for audio only and would wait if the update is related to video. On a related note, some of the high bitrate wav and wma files did not play with the plugin installation from the madsonic site. With yours all of my formats play well, works as it should. Thank you!

 

 

docker stop <container name>

docker rm <container name>

docker rmi binhex/arch-madsonic

 

then issue the docker run command again to pull down image and create container, do NOT delete anything in your specified config folder.

 

tip - once you have created the container using the run command you can then stop/restart/start the container using the short container name, you dont need to specify the run command each time.

Link to comment
Is the transcode update related to video only?

 

no its for audio also, it supports things like flac audio transcoding to mp3 for playback on devices such as android, btw if you do have an android device i strongly recommend you grab the madsonic app from google play, its pretty good.

Link to comment

We are android users and I tested the madsonic app a while ago but found dsub to be more useful, especially streaming in my car. Has madsonic improved in the last couple of months?

I spent a great deal of time yesterday installing the previous version, I may have to wait till next weekend to get around to this update :(

 

Is the transcode update related to video only?

 

no its for audio also, it supports things like flac audio transcoding to mp3 for playback on devices such as android, btw if you do have an android device i strongly recommend you grab the madsonic app from google play, its pretty good.

Link to comment
  • 2 weeks later...

I'm having a little trouble....it's probably not a repo issue, but I think someone in this thread might know what's going on.

 

This input in terminal

 

docker run -d -p 4040:4040 --net="host" --name="madsonic" -v /mnt/user:/media -v /mnt/user/madsonicdata:/config -v /etc/localtime:/etc/localtime:ro binhex/arch-madsonic

 

Yields this output

 

Unable to find image 'binhex/arch-madsonic' locally
Pulling repository binhex/arch-madsonic
2014/09/17 00:20:15 Get https://index.docker.io/v1/repositories/binhex/arch-madsonic/images: dial tcp: lookup index.docker.io: file exists

 

And nothing happens.

 

Why is it so?

 

A docker image has been created separately prior to the docker pull attempt.

 

Any pointers greatly appreciated

 

Dan

Link to comment

I replaced the madsonic version to the latest image and see that it keeps crashing every day, the previous version ran without crashing for a week at least before I upgraded. I have copied below the log .. can you please look into it? I use this plugin extensively. TIA!

 

-------

 

2014-09-16 18:22:55,788 DEBG fd 6 closed, stopped monitoring (stdout)>

2014-09-16 18:22:55,789 DEBG fd 8 closed, stopped monitoring (stderr)>

2014-09-16 18:22:55,789 INFO exited: transcode (exit status 0; expected)

2014-09-16 18:22:55,789 DEBG received SIGCLD indicating a child quit

2014-09-16 20:39:54,750 DEBG 'madsonic' stderr output:

/var/madsonic/madsonic.sh: line 155: 16 Aborted ${JAVA} -Xms${MADSONIC_INIT_MEMORY}m -Xmx${MADSONIC_MAX_MEMORY}m -Dmadsonic.home=${MADSONIC_HOME} -Dmadsonic.host=${MADSONIC_HOST} -Dmadsonic.port=${MADSONIC_PORT} -Dmadsonic.httpsPort=${MADSONIC_HTTPS_PORT} -Dmadsonic.contextPath=${MADSONIC_CONTEXT_PATH} -Dmadsonic.defaultMusicFolder=${MADSONIC_DEFAULT_MUSIC_FOLDER} -Dmadsonic.defaultUploadFolder=${MADSONIC_DEFAULT_UPLOAD_FOLDER} -Dmadsonic.defaultPodcastFolder=${MADSONIC_DEFAULT_PODCAST_FOLDER} -Dmadsonic.defaultPlaylistImportFolder=${MADSONIC_DEFAULT_PLAYLIST_IMPORT_FOLDER} -Dmadsonic.defaultPlaylistExportFolder=${MADSONIC_DEFAULT_PLAYLIST_EXPORT_FOLDER} -Dmadsonic.defaultPlaylistBackupFolder=${MADSONIC_DEFAULT_PLAYLIST_BACKUP_FOLDER} -Duser.timezone=${MADSONIC_DEFAULT_TIMEZONE} -Djava.awt.headless=true -verbose:gc -jar madsonic-booter.jar > ${LOG} 2>&1

2014-09-16 20:39:54,779 DEBG 'madsonic' stdout output:

Started Madsonic [PID , /config/madsonic_sh.log]

2014-09-16 20:39:54,885 DEBG fd 9 closed, stopped monitoring (stdout)>

2014-09-16 20:39:54,885 DEBG fd 13 closed, stopped monitoring (stderr)>

2014-09-16 20:39:54,885 INFO exited: madsonic (exit status 0; expected)

2014-09-16 20:39:54,885 DEBG received SIGCLD indicating a child quit

-----------

 

Has madsonic improved in the last couple of months?

 

using the madsonic app on my android phone to stream from home works a treat!, i havent tried video streaming at all so cant comment on this, but mp3 streaming certainly is seamless for me.

Link to comment

I replaced the madsonic version to the latest image and see that it keeps crashing every day, the previous version ran without crashing for a week at least before I upgraded. I have copied below the log .. can you please look into it? I use this plugin extensively. TIA!

 

-------

 

2014-09-16 18:22:55,788 DEBG fd 6 closed, stopped monitoring (stdout)>

2014-09-16 18:22:55,789 DEBG fd 8 closed, stopped monitoring (stderr)>

2014-09-16 18:22:55,789 INFO exited: transcode (exit status 0; expected)

2014-09-16 18:22:55,789 DEBG received SIGCLD indicating a child quit

2014-09-16 20:39:54,750 DEBG 'madsonic' stderr output:

/var/madsonic/madsonic.sh: line 155: 16 Aborted ${JAVA} -Xms${MADSONIC_INIT_MEMORY}m -Xmx${MADSONIC_MAX_MEMORY}m -Dmadsonic.home=${MADSONIC_HOME} -Dmadsonic.host=${MADSONIC_HOST} -Dmadsonic.port=${MADSONIC_PORT} -Dmadsonic.httpsPort=${MADSONIC_HTTPS_PORT} -Dmadsonic.contextPath=${MADSONIC_CONTEXT_PATH} -Dmadsonic.defaultMusicFolder=${MADSONIC_DEFAULT_MUSIC_FOLDER} -Dmadsonic.defaultUploadFolder=${MADSONIC_DEFAULT_UPLOAD_FOLDER} -Dmadsonic.defaultPodcastFolder=${MADSONIC_DEFAULT_PODCAST_FOLDER} -Dmadsonic.defaultPlaylistImportFolder=${MADSONIC_DEFAULT_PLAYLIST_IMPORT_FOLDER} -Dmadsonic.defaultPlaylistExportFolder=${MADSONIC_DEFAULT_PLAYLIST_EXPORT_FOLDER} -Dmadsonic.defaultPlaylistBackupFolder=${MADSONIC_DEFAULT_PLAYLIST_BACKUP_FOLDER} -Duser.timezone=${MADSONIC_DEFAULT_TIMEZONE} -Djava.awt.headless=true -verbose:gc -jar madsonic-booter.jar > ${LOG} 2>&1

2014-09-16 20:39:54,779 DEBG 'madsonic' stdout output:

Started Madsonic [PID , /config/madsonic_sh.log]

2014-09-16 20:39:54,885 DEBG fd 9 closed, stopped monitoring (stdout)>

2014-09-16 20:39:54,885 DEBG fd 13 closed, stopped monitoring (stderr)>

2014-09-16 20:39:54,885 INFO exited: madsonic (exit status 0; expected)

2014-09-16 20:39:54,885 DEBG received SIGCLD indicating a child quit

-----------

 

Has madsonic improved in the last couple of months?

 

using the madsonic app on my android phone to stream from home works a treat!, i havent tried video streaming at all so cant comment on this, but mp3 streaming certainly is seamless for me.

 

from the look of that log it seems to quitting in a expected manner, this is not crashing, it looks like something is causing the docker container to stop, is your system running low on memory?, it is possible that OOM is kicking in.

 

2014-09-16 20:39:54,885 INFO exited: madsonic ([b]exit status 0; expected[/b])

Link to comment

I'm having a little trouble....it's probably not a repo issue, but I think someone in this thread might know what's going on.

 

This input in terminal

 

docker run -d -p 4040:4040 --net="host" --name="madsonic" -v /mnt/user:/media -v /mnt/user/madsonicdata:/config -v /etc/localtime:/etc/localtime:ro binhex/arch-madsonic

 

Yields this output

 

Unable to find image 'binhex/arch-madsonic' locally
Pulling repository binhex/arch-madsonic
2014/09/17 00:20:15 Get https://index.docker.io/v1/repositories/binhex/arch-madsonic/images: dial tcp: lookup index.docker.io: file exists

 

And nothing happens.

 

Why is it so?

 

A docker image has been created separately prior to the docker pull attempt.

 

Any pointers greatly appreciated

 

Dan

 

my advise would be to go from the top again, so delete the image file using

docker rmi <repository name>

, you can see downloaded images by issuing a

docker images

command, this will list all downloaded images, as you haven't managed to start madsonic it wont of created a container so no need to delete.

 

once deleted you can actually skip the docker pull command, instead simply issue a docker run command, this will pull down the image and create a container, so no need to do this as a two step process.

 

let me know how you get on.

Link to comment

Thanks for the advice.

 

I should offer some more information.

 

I'm using beta 9 and have just started out with docker - it seems a great alternative (and fun to boot) to the plugin system - which is how I have been running madsonic.

 

The output from the console has so far always been as I outlined i.e I have never had a successful docker pull - meaning to say no download image has ever been downloaded....for any dockerized app that I have tried to obtain, not just madsonic. I made sure to test a few different ones to see if the error was reproducible.

 

docker images

 

gives

 

REPOSITORY          TAG                 IMAGE ID            CREATED             VIRTUAL SIZE

 

No content.

 

Something is preventing downloads from any repository that I have tried. Always the same result - as previously listed.

 

No errors are seen in the sys logs I've looked at. Perhaps docker has a separate log somewhere?

 

Interestingly, this 'error' isn't really presenting itself as a bona fide error with its own message.

 

I am thinking it may be a permissions issue now...not sure where to start though.

 

 

 

Link to comment

ok it could well be permissions or there could be some corrupt tmp file in your docker image that is causing the issue (seen this on other posts), i think the easiest thing to do is blow away your docker image file and start again, especially seeing as you don't currently have any dockers pulled down.

 

so go into the webui/extensions/docker and click on stop, then delete docker image file on your cache drive, then put the path in again, so something like "/mnt/cache/<cache only share name>/docker/docker.img" my advise is to set it to around 10GB in size.

 

click on start and make sure the image file is created.

 

then try using "docker run...." again.

Link to comment

ok madsonic 5.1 final is out!!, ive updated the docker image so please stop container, remove container, remove image and then issue a docker run to pull down the new version.

 

there is a recommendation on the madsonic forum to perform a clean install when moving to 5.1 as there have been database schema changes, so if your having issues then please try deleting the database and re-scan before posting any issues, enjoy!!.

Link to comment

finally came around to install binhex version and botez parallel. installs all fine over docker gui. but wenn i try to edit the ports. what i get is:

 

root@localhost:# /usr/bin/docker run -d --net="bridge" -e TZ="America/Bogota" -p 4041:4040/tcp

Usage: docker run [OPTIONS] IMAGE [COMMAND] [ARG...]

Run a command in a new container

-a, --attach=[] Attach to STDIN, STDOUT or STDERR.

-c, --cpu-shares=0 CPU shares (relative weight)

--cap-add=[] Add Linux capabilities

--cap-drop=[] Drop Linux capabilities

-d, --detach=false Detached mode: run container in the background and print new container ID

--device=[] Add a host device to the container (e.g. --device=/dev/sdc:/dev/xvdc)

--dns=[] Set custom DNS servers

--dns-search=[] Set custom DNS search domains

-e, --env=[] Set environment variables

--env-file=[] Read in a line delimited file of environment variables

--expose=[] Expose a port from the container without publishing it to your host

-i, --interactive=false Keep STDIN open even if not attached

--link=[] Add link to another container in the form of name:alias

'bridge': creates a new network stack for the container on the docker bridge

'none': no networking for this container

'container:': reuses another container network stack

'host': use the host network stack inside the container. Note: the host mode gives the container full access to local system services such as D-bus and is therefore considered insecure.

-P, --publish-all=false Publish all exposed ports to the host interfaces

-p, --publish=[] Publish a container's port to the host

format: ip:hostPort:containerPort | ip::containerPort | hostPort:containerPort

(use 'docker port' to see the actual mapping)

--privileged=false Give extended privileges to this container

--rm=false Automatically remove the container when it exits (incompatible with -d)

--sig-proxy=true Proxy received signals to the process (even in non-TTY mode). SIGCHLD, SIGSTOP, and SIGKILL are not proxied.

-t, --tty=false Allocate a pseudo-TTY

-v, --volume=[] Bind mount a volume (e.g., from the host: -v /host:/container, from Docker: -v /container)

--volumes-from=[] Mount volumes from the specified container(s)

 

The command failed.

 

i tried all kind of variations, as host or bridge, container started or stopped

 

any ideas or settings for docker gui would be appreciated.

 

Cheers, L

Link to comment

hi lars, basically this is spitting out the help screen for docker as your command line format is incorrect:-

 

root@localhost:# /usr/bin/docker run -d --net="bridge" -e TZ="America/Bogota" -p 4041:4040/tcp

 

the environment variable is causing the issue, and even if this was corrected botez docker doesnt support setting the time zone info, you can only define the following:-

 

HOST=0.0.0.0

PORT=4040

CONTEXT_PATH=/

MAX_MEMORY=1200

 

ok done a bit of work for you, just replace anything in <> with your path and copy and paste the command into a ssh session and it will work:-

 

madsonic-binhex

docker run -d -p 4040:4040 -p 4050:4050 --name=madsonic-binhex -v <path for media files>:/media -v <path for config files>:/config -v /etc/localtime:/etc/localtime:ro binhex/arch-madsonic

 

madsonic-botez

docker run -d -p 4060:4040 -v /mnt:/mnt -v <path for config files>:/config -v /etc/localtime:/etc/localtime:ro –name=madsonic-botez botez/docker-madsonic

 

you then access botez via port 4060 and mine via port 4040 (http) or 4050 (https)

Link to comment

hi lars, basically this is spitting out the help screen for docker as your command line format is incorrect:-

 

root@localhost:# /usr/bin/docker run -d --net="bridge" -e TZ="America/Bogota" -p 4041:4040/tcp

 

the environment variable is causing the issue, and even if this was corrected botez docker doesnt support setting the time zone info, you can only define the following:-

 

HOST=0.0.0.0

PORT=4040

CONTEXT_PATH=/

MAX_MEMORY=1200

 

ok done a bit of work for you, just replace anything in <> with your path and copy and paste the command into a ssh session and it will work:-

 

madsonic-binhex

docker run -d -p 4040:4040 -p 4050:4050 --name=madsonic-binhex -v <path for media files>:/media -v <path for config files>:/config -v /etc/localtime:/etc/localtime:ro binhex/arch-madsonic

 

madsonic-botez

docker run -d -p 4060:4040 -v /mnt:/mnt -v <path for config files>:/config -v /etc/localtime:/etc/localtime:ro –name=madsonic-botez botez/docker-madsonic

 

you then access botez via port 4060 and mine via port 4040 (http) or 4050 (https)

 

hi binhex,

first of all thx for response/ help and the efforts. but i need that exactly opposite for now  ::)

the botez on 4040 and you on 4041.  the failure try above is based on your madsonic release.

i wasn't really clear last night in terms of problem. so basically, your idea is valid - change the botez versions port, but it causes problems due to ppl.

 

i have botez' version running pretty much all set up to the needs at time. i have also about 10 friends on that, sharing. botez' at the 4040 port at the moment, so i don't really want to change that for the time being. i was trying to change the port settings on your container. and keep failing with the above results in variations. i use gfjardims's docker gui, for all that (i tried with putty as well). basically i try to do what seemed no prob. for pinion - keep botez on 4040 and set binhex to 4041 and 4051 instead of 4040 and 4050 ports. along the lines, let the working one work for the guys and use the other one to set up from scratch, scan media in and run some time trials as well and finally basically having everything to my liking's again simply adjust the ports to connect to the better performing one - without any downtime for my friends.

sth i noticed while trying versions was, botez' is running as Host your's as Bridge mode (is there a reason?), might i have to set botez on Bridge as well maybe? at the moment it seems like both containers are generally running (botez is still the one i get in my browser even when both are running - one would expect some kind of conflict...) under docker - i just don't get yours to show in browser (chrome, firefox or opera). might there be something else i just don't know - like do i have to change network settings of unraid maybe, st botez to bridge as well to make it work (i think i tried that last nite, not 100% sure about). maybe pinion can chime in about his settings for both - since it seems to work for him!? plz?

 

cheers and thx for all the effort so far already

Lars

 

 

Link to comment

When I was running both this is the command I used to start binhex's on alternate ports. I used https, 4041 isn't going to work if you pass in the https port 4050. You'll need to go to https://Tower:4050 (or 4051 in my case). I saw when I was running it because I've forked botez's and added in the value to use https so I could have https and the phusion base.

 

docker run -d -h unraid --name="binhex-madsonic" -v /mnt/user:/media -v /mnt/cache/docker/apps/appdata/binhex-madsonic/:/config -v /etc/localtime:/etc/localtime:ro -p 4041:4040 -p 4051:4050 binhex/arch-madsonic 

Link to comment

ok firstly i have no idea why botez has his docker container running as host but in that mode the -p flag is completely ignored, so you cannot specify a different port on the host side without changing to bridge mode, personally i only use host mode if i cannot get the docker container to connect correctly, Plex Media Server being one.

 

so if you want to run my docker on a different port then simply use the following:-

 

docker run -d -p 4050:4040 -p 4060:4050 --name=madsonic-binhex -v <path for media files>:/media -v <path for config files>:/config -v /etc/localtime:/etc/localtime:ro binhex/arch-madsonic

 

you then connect to my docker using port 4050 for http or 4060 for https, e.g. https://<unraid-ip-address>:4060

 

basically the way the ports work is host side is on the left of the colon for the -p flag and docker side is on the right, you shouldnt change the right side, you should only ever change the port on the left side, as long as its unique then it will work.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.