Moving From CasaOS To Straight Docker Compose

Moving From CasaOS To Straight Docker Compose

Google Gemini, The SysAdmin Guide I Didn’t Know I Needed

Last week’s update ended with me wondering if I could bridge the gap between a 3TB and a 4TB drive without breaking Fedora Server on my Lenovo ThinkStation. Since then, I’m happy to report that I’ve made lots of progress, both in the ThinkStation Fedora Server playground and my daily driver NukBox! 

Rather than tapping the help of a sysadmin friend who could answer my questions in his sleep, I relied heavily on Google Gemini to walk me through each step. I asked it questions on how to do X, Y, or Z. It would respond with helpful information and terminal prompts. I’d enter them and post results on whether or not they were successful. We went back and forth like this for each task below until everything was working the way I’d hoped. Overall, Gemini served as a super efficient guide to help me learn the ins and outs of container management in both Podman and Docker.

Mirroring Drives with ZFS and Podman

On the ThinkStation, I managed to resolve the ZFS storage puzzle. Even though I had mismatched drive sizes (3TB and 4TB), the ZFS mirror keyword handled the math for me. It automatically matched the smaller 3TB drive and trimmed the 4TB one to fit. This gave me a rock-solid mirrored 3TB pool.

With storage ready, I dove into Podman. I successfully created containers for Joplin Server, Syncthing, and Calibre. While I didn’t get very far with the configurations for those specific apps, getting familiar with creating containers in Podman is a win. The learning curve is there, but the Red Hat way is starting to make sense.

The CasaOS Breaking Point

While I was considering which task to pick up next, CasaOS on my daily driver NukBox started acting up again. CasaOS has a major friction point because it does not support the latest versions of Docker. Every time my system did a routine update, the CasaOS dashboard would lose my apps and they would fail to load.

I am now quite the expert at the not-so-painful way to downgrade Docker on Debian Linux. If you ever find yourself needing to force Docker back to a version CasaOS likes, here is the survival kit I used:

  • Update the package list: sudo apt update
  • List available versions: apt-cache policy docker-ce
  • Stop the Docker service: sudo systemctl stop docker
  • Remove current packages: sudo apt remove -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
  • Install the specific older version: sudo apt install -y docker-ce=[VERSION_STRING] docker-ce-cli=[VERSION_STRING] containerd.io

I used version 5:28.3.2-1~debian.12~bookworm to get things running again. After doing this for the umpteenth time, I realized I was spending more time fixing my server than using it. It was time for a change.

Liberating Immich and Paperless-ngx

Instead of waiting until I was a Podman expert, I decided to take the simpler path from my previous post. I decided to migrate my Docker containers out of CasaOS and into Docker Compose.

Rather than starting with the easiest application, I chose to migrate my most important and complex application: Immich. This is my self-hosted photo engine, and it has a lot of moving parts like databases and machine learning microservices. Amazingly, the migration worked while encountering very few challenges. I mapped out the environment variables and volume paths CasaOS was using and translated them into a standard docker-compose.yml file.

immich on docker compose

Following Immich, I moved Paperless-ngx. This is another vital app for my digital organization, and moving it to its own Compose file was a smooth process. Immich and Paperless-ngx were the first of my self-hosted applications to be liberated from CasaOS!

paperless on docker compose

Moving the Rest of the Fleet

Once I realized I could successfully migrate the more complex apps, the rest of the dominoes started to fall:

Portainer: Since Portainer is actually just a tool to manage other Docker containers, it was one of the easiest to unhook from CasaOS.

thinkstation portainer dashboard

Joplin Server: After Portainer, I moved onto a more vital application that I use frequently. This one was a bit more stubborn because the server kept trying to use a default SQLite database instead of the PostgreSQL database I wanted.

joplin server dashboard

After some troubleshooting with the environment variables and the database connection strings, I finally saw the “Success” message on my sync check. I ended up starting with a fresh database on the server and syncing my notes up from my laptop, which served as the master copy.

For The Next Episode

My NukBox is currently a hybrid. My most vital applications are now running as pure Docker Compose projects. They are stable and they don’t care if I update Docker. Most importantly, I have total control over their configuration.

The only applications still living in the CasaOS dashboard are Calibre, Calibre-web, and Home Assistant. These are the last ones I need to transition before I can retire the CasaOS interface for good. One thing I still need to figure out is a solid file management container similar to the Files app in CasaOS. I really like the convenience of that GUI for browsing my server folders, so finding a standalone Docker alternative is next on my list.

After those small tasks, I’ll return the the Cockpit+Podman playground and consider what experiments to do next.

The journey from being scared of the terminal to creating my own YAML files has been a wild ride. Like I said last time, learning new technologies keeps the brain muscles strong!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Scroll to Top