If you have a ton of audiobooks like I do and are looking for an easy way to stream your books, look no further! Booksonic should be on the top of your list if you’re considering self-hosting. Booksonic has mobile device applications, is open-source, and is easy to use in a docker image setup natively, on Portainer, or even Rancher or Yacht.
To host my Booksonic audiobook server, I will use a docker image created by linuxserver.io. You can find the image and deployment options on their website: linuxserver/booksonic-air – LinuxServer.io. I am hosting this on a raspberry pi and set up the app in Portainer by simply creating a new container as I knew all my variables and input paths to populate the information quickly. However, I could have deployed a stack through Portainer, copied their docker-compose information, and created a YAML. LinuxServer.io makes the process easy and educates plainly on how to deploy all their images quickly.
Following how I deployed the image, I created a new container from the Portainer Container page. I named the container appropriately and populated the docker.io image as lscr.io/linuxserver/booksonic-air:latest (please note this is different from the example in the screenshot before I updated my container). I also updated the ports as 4040 for both the host and container.
I mount each container volume to the specific locations I determined on my attached drives on the Volumes tab. In this case, I am running OMV and had pre-mapped places for my audiobooks, configs, and podcasts.
Moving to the environment tab, set your variables as shown in the snapshot here. Typically, this is the default as to what is deployed by the image pull, but you will want to update your PUID and PGID to match what is assigned to your username on your pi. For example, to find this, open a terminal on the pi you are installing on and type: id username (replacing username with the username you are using, i.e., pi). This will return your UID and GID values. Deploy your container and wait for deployment notification to confirm the container has started. Before deploying the container, move to the restart policy and adjust to “restart unless stopped.”
We will need to set up a way to connect to our audiobook server over the internet. I added a sub-domain to point to my IP Address. I recommend Cloudflare. At least that is who I use to host my DNS, it’s free, and they will proxy your IP.
If you are less familiar with deploying containers in this way, then use a new “Stack” instead of in Portainer and deploy with docker-compose:
--- version: "2.1" services: booksonic-air: image: lscr.io/linuxserver/booksonic-air container_name: booksonic-air environment: - PUID=1000 - PGID=1000 - TZ=Europe/London - CONTEXT_PATH=url-base volumes: - </path/to/appdata/config>:/config - </path/to/audiobooks>:/audiobooks - </path/to/podcasts>:/podcasts - </path/to/othermedia>:/othermedia ports: - 4040:4040 restart: unless-stopped
Update environment and volume information as desired.
That’s it. You should be up and running. You add and remove audiobooks by moving them into the audiobooks folder you mapped to in the container image. If an image does not auto populate then add it to the folder of the audiobook that is missing the image. Booksonic will pick that up as part of the data and display the chosen image you placed in the folder.
Interested in installing Open Media Vault (OMV) to run your images on Portainer and store your media? Click on this blog post to learn how: Installing OMV.
Adding Apps to Mobile Devices
When I was thinking about installing an audiobook server, I wanted one that would interface cleanly with my iPad, my iPhone, an Android phone, and a PC. With access to the internet, the image above makes using Booksonic easy from any computer and an OK experience from a tablet. However, being able to use an app on mobile devices and tablets really interested me! On Android, you have many choices. Any app that supports subsonic will support book sonic, both paid and free. However, options are a little thin on Apple iOS, but I will give you my recommendations.
For Apple iOS, I am using an app from the App Store called iSub. The app works great. It does not have a lot of bells and whistles but is perfect for streaming, bookmarking, and downloading to your device. It’s straightforward to use, but made to support a variety of self-hosted platforms, so many of the features seem a bit generic. With that said, I have had zero issues connecting to my server and streaming my audiobooks. Setup is straightforward, enter your URL for your server and credentials and it will do the rest.
I recommend spending $2.99 and installing the Booksonic app for Android devices. This app was designed to interface with Booksonic and displayed beautifully how you would expect the mobile app version to be and is fully featured as you would have on the PC version. Set up is easy, just as on iSub, and is very quick. Found in the Play Store as Booksonic
If you’re looking to set up an audiobook server like this, I hope you try Booksonic. It is easy to use, open-source and has plenty of support online. I am also happy to help if you leave a comment!