MyMedia on Docker Suddenly Stopped Working

Post Reply
wizbowes
Posts: 1
Joined: Mon May 24, 2021 8:44 pm

MyMedia on Docker Suddenly Stopped Working

Post by wizbowes »

MyMedia on docker has suddenly stopped working. Alexa claimed to start playing the track, but there was no sound. I logged onto the server page, and was presented with a Welcome to MyMedia page, and had to link my amazon account. Now it appears that I have 2 servers. One, a new one, which has a home icon next to it, shows the docker internal IP address; the other, the proper server I want / need to use as it has the correct external IP address, shows the external IP address of the server it should be connecting to.

All port mappings remain unchanged in the docker config,
There has been no update to the docker image file for years.
I'm unable to change from the incorrect server to the correct server
I'm completely unable to use MyMedia currently.

My Docker Compose config: myMediaServer:

Code: Select all

   container_name: myMediaServer
    image: "bizmodeller/mymediaforalexa"
    ports:
        - "52050:52050"
        - "52051:52051"
    volumes:
        - /home/pi/torrents:/medialibrary 
        - /home/pi/docker/myMediaServer:/datadir
        - /usr/bin:/usr/bin
    restart: unless-stopped
 
Screenshots showing the issue:
MyMedia.png
MyMedia.png (128.35 KiB) Viewed 5723 times

Please can you assist.
bizmodeller
Posts: 458
Joined: Thu Nov 14, 2013 8:40 pm

Re: MyMedia on Docker Suddenly Stopped Working

Post by bizmodeller »

Apologies for the delay. It looks like the previous instance of the docker container was restarted and the configuration file was not persisted to the new instance of the docker container. My Media's settings should be persisted outside of the docker contianer because otherwise, they will be lost on restart of the container. So we suggest mapping as follows:

docker run -d -p 52050:52050 -p 52051:52051 -v ~/Music:/medialibrary -v ~/.MyMediaForAlexa:/datadir bizmodeller/mymediaforalexa

In this case your local ~/.MyMediaForAlexa folder will be mapped inside the container as the data directory which should persist the set up info between container restarts. It's important in this case to ensure that docker starts as the same user otherwise a different user's home directory could be used for the mapping which would also generate these symptoms.

If the container restarts without this persisted data, it will be like a fresh install, and create a new server GUID. If you repair with your account, we will see this as a fresh installation against your Amazon email address which is why you see two. You can't delete the new server because that is the server you are running. You can delete the other one because it's old and not running.

So in your situation, we would suggest:
1. Check your set up to ensure that the datadir is being persisted to a directory that is stable
2. Set up the new server instance the same as the old one, i.e. update the exposed IP address to be the external docker NAT'd address and reset up watch folders.
3. Remove the old server instance from the UI.
4. Test stopping, deleting and recreating the container with the same mapped datadir to ensure that the configuration persists across container re-creation
Post Reply