I’m replying 5 years later as this is still a top SEO’d page for this question.
I’ve run multiple blogs both using the Ghost CLI and using containers, so I can speak to the trade-offs.
As @Kevin said, right now the Ghost CLI route is the officially supported method. But it has some drawbacks.
First, this is requires downloading another copy of Ghost for each install you want to upgrade, so upgrading several blogs can feel tedious.
The Ghost CLI tool provides a pleasant, interactive experience and has some built in checks for common problems and can provide you some interactive feedback about what’s wrong.
At the same time, the Ghost CLI has some drawbacks. Because it uses a system node
and not a bundled node, some people run into node version mismatch problems. For example, they just assume they can upgrade to the latest version of Node without checking if Ghost supports it yet. Or they upgrade Node to support some non-Ghost project, or they upgrade their OS and end up with a different version of Node. Whatever the reason, they end up a state where Ghost won’t start because the Node version is wrong.
Running Ghost in a container solves multiple problems:
- It bundles the correction of Node needed by each version of Ghost
- Only one copy of each Ghost version needs to be downloaded for multiple blogs. Unique containers will be created based on the single image for a version.
- No more conflicts between the version of Node needed by Ghost and other projects on your system.
While the container install method may be considered more advanced, it’s a common pattern in in 2024 for self-hosting projects. If plan to self-host more besides Ghost, there’s a good chance other projects expect you to know how to host containers so you may need to figure out anywhere. It can be done with the CLI or with GUI apps like Proxmox or Fedora’s Cockpit with it’s Podman support.
Running Ghost in a container also adds some challenges:
- The container will not handle setting up a reverse proxy
- The container will not set up a secure certificate.
- You’ll need to make sure the container starts at boot.
While I use a DIY method myself, there are now projects which help with the details of running containers like Traefik, which will take care of the three points above for you. Traefik Proxy Documentation - Traefik Another option is Portainer, which offers a free community edition for personal use. https://www.portainer.io
While I originally recommended the Ghost CLI method because it seems simpler and is officially supported, in 2024 I recommend hosting as containers, because it solves some problems and odds are if you are hosting Ghost are you are self-hosting things as well, and other projects now commonly use containers as their officially supported hosting method.
Ghost 6 will be the most complex release to date, involving a second service for the first time, an ActivityPub server. That would be an ideal time to start officially using containers to host the project and maybe they will. Choosing to run Ghost in a container now is likely a forward-looking choice.