Opus Is My Hot Rod

In addition to being a writing outlet, Opus consistently gives me opportunities to roll up my sleeves and tinker.
1977 Pontiac Trans Am
I’m sure it’s an absolute blast to drive, but I would never want to take care of it

I have some friends who are what you’d call “car guys.” Peek in their garages, and you’ll find classic muscle cars, sleek European roadsters, and tuned up Japanese sportsters. These are more then mere vehicles, though; they’re labors of love. Indeed, I suspect that for my friends, the countless hours spent maintaining their cars — be it hunched over the engine, cleaning and restoring the interior, or replacing a part that took considerable time and effort to track down — are just as important, meaningful, and fun as actually driving them.

I, on the other hand, am most decidedly not a car guy. My car is just a vehicle that takes me where I need to go, and the less time I can spend thinking about it, the better and happier I’ll be. I am, however, a website guy. And over the years, Opus has essentially served as my own personal hot rod. Only I’m not out in garage, hunched over the engine. Rather, I’m hunched over my keyboard. But I’m maintaining, restoring, cleaning, and tinkering all the same.

Indeed, the last month or so have seen some pretty significant updates to Opus, albeit updates that are largely behind the scenes.

New Detailing

Historically speaking, I tend to redesign Opus approximately every year and a half, often after I’ve discovered some new design style or web development technique that I want to try out. I wish I kept better records of all of the site’s many redesigns, but I believe the current design — the one with the blue/red gradient in the header and footer — has been in place for almost two years now, if not longer, making it one of my more successful designs. But while it’s probably looked more or less the same to readers during that time, I’ve actually rewritten the design’s underlying HTML and CSS three times, at least.

The most recent rewrite was last month, and was mainly intended to 1) streamline the CSS, 2) implement a new design for the “Cultural Diet” section, 3) improve and enhance the colors for visual and accessibility reasons, and 4) make the site’s typography more consistent.

And even in-between these full rewrites, I’ve refactored the site’s CSS numerous times to reduce it as much as possible. The site’s current (minified) stylesheet is just under 25 KB in size, and that’s before compression. (After compression, it’s around 7 KB.) In the past, I’ve gone so far as to break apart the CSS and embed/inline certain styles only on those pages where they’re needed. (For example, embedding the CSS necessary for “banner” layouts only on posts using that layout, like this one.)

I might do that again at some point, but while breaking apart the CSS can shave off a few KB here and there, it introduces other inefficiencies with regards to code maintenance and upkeep that I want to avoid for now.

Under the Hood

Opus currently runs on Craft, and one of the things I love most about Craft is its incredibly flexible approach to content modeling. Basically, Craft stores site content in sections, and each section can have multiple entry types, and each entry type can have its own assortment of custom fields. Similarly, Craft lets you create multiple taxonomies and folksonomies (i.e., categories and tags) that, like entry types, can also have their own assortments of custom fields. Finally, you can mix and match your entry types, taxonomies, and folksonomies to your heart’s content.

This out-of-the-box flexibility can be a bit overwhelming if you’re used to, say, WordPress, but it’s one of Craft’s killer features, and I’ve used it in many ways (e.g., managing and organizing the site’s many images). One reason why it can be overwhelming is because entries, categories, and tags are essentially the same thing, at least far as Craft is concerned — which can raise questions as to the “right” way of modeling your site’s content.

This is why Craft’s developers announced last year that they’d be doing away with all such distinctions:

From a pure content modeling perspective, there’s no significant difference between a category group and a Structure section. Or a tag group and a Channel section. Or a global set and a Single section. In each case, using a section would have been just as effective at handling the content needs, with a slightly different authoring UX.

These similarities can lead to a bit of choice paralysis when it comes to building out a content model for new projects, particularly for green developers who haven’t had a chance to grok the impact their choices will have for content managers.

So that’s why we’ve decided it’s time to simplify. Category groups are going to become Structure sections; tag groups will become Channel sections; and global sets will become Single sections.

I spent some time last month running a series of command line scripts to “entrify” all of Opus’ categories and tags. (Kudos to Craft’s team for making said scripts work as smoothly as they did.) Of course, if I hadn’t told you any of this, you would never have noticed anything. You can browse all of my music and movie-related posts, for instance, or still see everything that I’ve ever written about Slowdive, Jackie Chan, or The Hobbit just like you always could. Behind the scenes, however, this ensures that Opus will be fully compatible with future Craft updates.

(One downside: I used lots of taxonomies and folksonomies, so after converting them all to entries, my admin area is a bit more complicated than I’d like. Craft’s built-in custom sources functionality ameliorates that somewhat, but I’m eager to see the unified “Content” view that’s currently planned for Craft 6.)


It’s more likely that you noticed this particular behind-the-scenes change. Several weeks ago, Opus kept going offline, which required restarting Apache and MySQL even multiple times a day. After a deep dive into the server logs, the issue was that Opus kept running out of memory. In other words, Opus was getting so much traffic that it was getting knocked offline, which isn’t a bad problem to have.

I’ve since migrated Opus to a more powerful hosting environment — DigitalOcean droplets for the win! — and have had zero performance issues to date. Over the years, I’d been pleasantly surprised that I was able to run Opus on such a small — and cheap — hosting setup. But that time has apparently passed. I’m still exploring some additional hosting options, and will probably spend some time this summer building out an entirely new hosting environment for the site.

Shameless plug: If you’d like to support Opus, including the cost of hosting a site viewed by thousands of readers every month, become a subscriber today.

All of this work isn’t exactly necessary, but just like my friends’ prized muscle cars and roadsters, Opus has always been a labor of love and a nice excuse to roll up my sleeves and get my hands dirty… so to speak.

Enjoy reading Opus? Want to support my writing? Become a subscriber for just $5/month or $50/year.
Subscribe Today
Return to the Opus homepage