When deploying Discourse in a self-hosted environment, so not utilizing the managed Discourse hosting provided by its development company, one would go about following their excellent install guide over on the Discourse GitHub repository, https://github.com/discourse/discourse/blob/main/docs/INSTALL-cloud.md.
However, when you are appointing one of Webdock's perfect servers to be the host of your Discourse forum, then there are a few steps to be aware of before you can be successful with the installation.
In the remainder of this guide we expect you have already gone through these steps:
- Deployed a server with the "SSD Bit" hardware profile or higher (SSD Nano and SSD Nano4 provide too few resources for Discourse to run performant) and selecting "Recommended OS" with Ubuntu Focal 20.04 (essentially a clean Ubuntu install) as your image
- Configured the server with any security settings you see fit (there will be a separate post from me which settings and tools I suggest for this)
- Installed Docker and changed the storage driver with the help of this guide: https://webdock.io/en/docs/how-guides/docker-guides/how-to-install-and-run-docker-containers-on-webdock-ubuntu-server?sid=EpsilonSynapse&maff=wdaff--116
- Proceeded up to (not including) Step 5 in the Discourse install guide linked in the Introduction of this post
Necessary changes to the Discourse deployment
Now comes the interesting stuff.
Go ahead and proceed with Steps 5 and 6 of the Discourse install guide.
During step 6, when you execute
./discourse-setup, the launcher will warn you about an unsupported storage driver:
Your Docker installation is not using a supported storage driver. If we were to proceed you may have a broken install. overlay2 is the recommended storage driver, although zfs and aufs may work as well. Other storage drivers are known to be problematic. You can tell what filesystem you are using by running "docker info" and looking at the 'Storage Driver' line. If you wish to continue anyway using your existing unsupported storage driver, read the source code of launcher and figure out how to bypass this check.
Because you had to change the storage driver Docker uses on your Webdock server, this happens.
But, from my research and production testing, this warning can be ignored. My own Discourse deployment (the community forum of this blog, which also provides the comment function for it) is running on Webdock with this changed storage driver without problems.
Stop the launcher with
Ctrl+C, which will drop you back to the command line.
We will now disable the storage driver check so we can proceed with the installation.
Open the 'launcher' file, either with
vi launcher or
nano launcher, depending on which editor you are more comfortable with, and scroll down to line 175.
In there the following is written:
This section should be familiar to you now since it is essentially the same text as the error message, only surrounded by some Linux syntax.
Go ahead and add a # before lines 175 to 184, so it looks like this:
This will ensure that the storage driver check is disabled and you can proceed with the installation of Discourse on your Webdock server.
Start the installation again from Step 6 of the Discourse install guide and you should hit no more roadblocks on the way to an awesome forum!
If you should notice any or all of the errors mentioned here (https://meta.discourse.org/t/various-errors-during-recent-install/235361), don't worry about them for now, they shouldn't impact your environment. If you like, follow that thread to see what the devs have to say about it.
Following this blog post you should now have a functioning Discourse instance on your brand new Webdock server. Congratulations!
If you encounter any problems, go to the comments section below and let me know, I will do my best to help.
You don't pay any extra for the usage of these links.
Thank you for supporting the author and this blog!