docker run --name=ampache -d -v /path/to/your/music:/media:ro -p 80:80 idelsink/ampache
There are extra ports that can be passed to the container using the
The ports are:
- 80: http: ampache
- 443: (not used but https for the future)
- 9001: supervisord web UI (used to manage services)
- 32400: plex interface (see See Plex backend)
To set the correct timezone in the Docker container, the
variable can be set. This can be done by adding the following to the
This would result in:
docker run --name=ampache -e TIMEZONE="Europe/Amsterdam" -d -v /path/to/your/music:/media:ro -p 80:80 idelsink/ampache
- Get MySQL root password (Found in terminal or in a file in the
/rootdirectory in the container)
- Launch website (<url/ip> or localhost)
- Fill in obtained root credentials
- Add new database user
- Installation type: whatever you like
- Transcoding: Template Configuration => ffmpeg
- Players: do whatever you like (See Available Players)
- Create config
- Create admin account
- And you're done!
- Now just add your catalog(s) end configure it like you want it.
After starting the docker image as a daemon process,
look at the logs for the pseudo-random generated MySQL root password.
docker logs ampache # or for tailing the log file docker logs -f ampache
The output would look something like this:
~~ First time setup of MySQL ~~ => An empty or uninitialized MySQL volume is detected in /var/lib/mysql => Installing MySQL ... => Done! => Trying to secure database => Starting MySQL service.................... => Databse is less vulnerable now; Stopping MySQL service ======================================================================== Random generated MySQL root password is: 'JPVxOlJhAioadRg16OfmLUTY648j7BeS9r1N8vgOY9qUsRYOgh6u5Dz8CSmqFqw84OjYT1XX9Of8X6' Change the above password if deemed necessary. MySQL user 'root' only allows local connections. ======================================================================== ~~ Container date output: Wed Jul 26 22:09:31 UTC 2017 ~~ ~~ Starting the service manager supervisord ~~
Follow the rest of the steps from the installation summary.
To setup the Plex backend do the following:
- Pass an extra port parameter while starting docker for the Plex backend pointing to port
For example add
-p 32400:32400to the
- If not already done so during the Ampache setup process, enable the Plex backend at
System > Use Plex backend > Enable
- Manually go to the
- Login with an Ampache account
- After login this page will NOT forward you to another page.
- Manually go to the
- Link Ampache to an existing Plex account.
- Setup port forwarding if applicable.
- Now use the official or any Plex application to browse/play your content. (tested with the official Plex application on Android 6.0.1)
Ampache is more than only a web interface. Several backends are implemented to
ensure you can stream your media from anywhere. Select backends to enable.
Depending the backend, you may need to perform additional configuration.
See wiki page.
- [x] Web interface
- [x] Ampache API
- [x] Subsonic
- [x] Plex
- [ ] UPnP
- [ ] DAAP (iTunes)
- [ ] WebDAV
To update to the newest docker image, if necessary, a backup can be made.
This is done by running a small script inside the docker container.
This will backup the database and Ampache configuration.
Backup / restore configurations
Follow these steps to perform a backup of Ampache.
Follow Steps 8 to (end) to restore a backup of Ampache.
Find your docker name / ID
Connect to the running container
docker exec -it <ID or name> sh
Run the backup script (inside the container)
mkdir /backup /scripts/backup.sh b /backup
Follow the instructions
Exit the docker container
Copy the files from the container to the host
docker cp <ID or name>:/backup ./backup
Update to the new/other container and let it finish configuring
Copy the files from host to container
docker cp ./backup <ID or name>:/backup
Restore the backup using the backup script
/scripts/backup.sh r /backup
Follow the instructions
Exit the container and you're done.
Some extra notes
- The MySQL root password can be found in the
- Make sure that your volume is mounted correctly, e.g. if using SELinux make sure to add the appropriate permission labels. (See this)
- Make sure not to use a port that is already used by another webserver/process.
You can check out the full license here
This project is licensed under the terms of the MIT license.