Supercharging WordPress with Fly.io, Bedrock, and SQLite
Posted in Hosting, Performance, WordPress — 5 minutes read
As a seasoned blogger and web developer, I’m always eager to explore new hosting solutions for my WordPress sites. Having previously tried Fly.io and been impressed by its simplicity and performance, I decided to venture into the world of Google Cloud and AWS, curious to see how they would stack up. Little did I know, my journey would lead me right back to where I started – Fly.io.
Paying the Price for Google Cloud
My initial foray into Google Cloud Run was driven by both professional and personal curiosity. With my workplace considering adopting the platform, I figured it would be a perfect opportunity to familiarize myself with its features and capabilities. Setting up a WordPress site on Cloud Run was relatively straightforward, and I was impressed by its seamless integration with Cloud SQL.
However, as I delved deeper, I discovered that the costs of running a WordPress site on Google Cloud Run could quickly escalate, particularly when using Cloud SQL for the database. Even for a small site, the database expenses alone were enough to give me pause. I began to question whether the benefits truly outweighed the financial burden, especially for a personal project like my blog.
Dipping My Toes in AWS
Not one to leave stones unturned, I decided to explore AWS as well. I was curious to see how it would compare to my experiences with Google Cloud Run and Fly.io. However, I quickly found myself overwhelmed by the sheer complexity of the AWS console. The learning curve was steep, and configuring essential features like auto-scaling and continuous deployment from Github felt like an uphill battle.
As I grappled with the intricacies of AWS, I couldn’t help but think back to the simplicity and ease of use I had enjoyed with Fly.io. I began to wonder if I had been too hasty in my decision to explore other options.
Finding Simplicity with Fly.io
Frustrated by the complexity of AWS and the high costs of Google Cloud Run, I decided to give Fly.io another look. I had heard about it, mainly from the Node community and I tried my hand at deploying a Laravel app to it in the past which turned out to be successful and quite straightforward.
With just a few commands, I was able to deploy my WordPress site seamlessly through Github Actions. Fly.io’s automatic scaling based on traffic was also a game-changer. No complex configurations needed – Fly.io handled the details automatically, scaling my site based on traffic. The only problem I ran into was setting up the Volume permissions to allow the PHP-FPM process to read and write to the SQLite database but this was solved fairly easily with a small tweak to my entrypoint.sh script.
A Modern WordPress Stack with Bedrock
While unrelated to cloud hosting itself, I decided to use Bedrock, an open-source project from Roots.io as the base for my project. Bedrock modernizes the WordPress folder structure and improves security and configuration management. With Bedrock, I could keep my WordPress site lean and organized, making it a perfect fit for containerization and deployment on Fly.io.
SQLite: Who Needs a Database Server?
But what about the database? Rather than using a heavy, expensive MySQL, I opted for SQLite. As a lightweight, file-based database, SQLite integrates directly into my site using the SQLite Database Integration plugin. No separate database server required, which further simplifies management and cuts costs. SQLite has been impressively stable and performant – I haven’t looked back. Note that your mileage may vary depending on the size of your site and the plugins you use however and I wouldn’t recommend this setup for larger sites.
Speed and Reliability in the Fly.io Cloud
Since moving my WordPress site to Fly.io, I’ve been consistently impressed by its performance and reliability. With Fly.io’s distributed global infrastructure, my site is lightning-fast, no matter where in the world visitors are located. Uptime has been rock-solid, letting me focus my energy on creating content, not battling infrastructure issues.
The Ideal WordPress Hosting Solution
After my experiences with Google Cloud Run and AWS, returning to Fly.io felt like coming home. The platform’s simplicity, performance, and cost-effectiveness perfectly aligned with my needs as a WordPress developer and blogger.
Fly.io, combined with Bedrock and SQLite, has become my go-to solution for hosting WordPress sites. It offers the scalability and reliability of cloud hosting without the headaches and high costs often associated with other platforms.
I can focus on what I do best – creating engaging content and connecting with my audience. The platform handles the underlying infrastructure seamlessly, allowing me to devote my energy to growing my site and brand. I wholeheartedly recommend giving Fly.io a try. Paired with Bedrock and SQLite, it’s a powerful combination that simplifies your workflow and maximizes your site’s potential. Your site (and your sanity) will thank you.