Image via Wikipedia
Since as far back as my memory goes I've been using Apache for my main, primary, and absolutely only webserver. It was the workhorse of everything from dev environments to production machines serving tens of pages.
But throughout this love affair there was one constant - I had to change things.
This isn't bad. Of course when you first start using mod_rewrite you're going to have to change things and naturally adding a new website on a new domain means changing a few things. No problem here, all natural.
But still, there was a certain feeling that rose up in me like a mad urge, a feeling of endless power and proportion, a feeling like, hey, I've had sex with this woman a few times, and I quite like it, but there's something missing something isn't quite right, why can't I watch a good movie instead of having this sex thing?
That's right, it was the Sense of Impending Doom. Because you see dearies, whenever you have to make a small change in the apache configs a small part of your soul dies. You know it's supposed to be a small change, you know it's supposed to be effortless, but despite having done this countless times, you still waste an hour making everything work.
This Saturday I finally stomped my foot like a little school girl and said ENOUGH! Then I installed nginx.
It was a bit daunting at first and I may still not know how to pronounce the name, but I love it. The damn thing is sooper fast and when I had to add a config for a new site ... hah! Took three lines of code, sure it was only for serving static files, but the same thing in apache takes a separate file, then a vhost, then blahlbah. Fuck you!
Here's an example, come on, would you see anything so sleek and awesome under Apache? Ever?
server {
listen localhost:80;
server_name lestat;
root /var/www;
index <a class="zem_slink freebase/en/webserver_directory_index" title="Webserver directory index" rel="wikipedia" href="http://en.wikipedia.org/wiki/Webserver_directory_index">index.html</a>;
}
Now obviously I don't know how to do fancy rewrites and stuff yet, but from what I've seen so far, I think nginx and Swizec are a match made in heaven for the foreseeable future.
So there you go @robertbasic, @genom, @loudandwicked, @jaspertandy ... a blog post about the change.
PS: about versatility and such that @genom mentioned, I haven't a bloody clue (yet)
PS2: apologies to everyone I mentioned in the post and didn't link to, Zemanta didn't suggest the links and I'm too lazy to do them manually.
Continue reading about Switching from apache to nginx is a dream
Semantically similar articles hand-picked by GPT-4
- The web moves fast, how do you keep up?
- Setting up a server only takes a while
- Yay my blog is up and running again! :D
- Even with Narwhals ubuntu is still a bitch to install
- Remember to feed your sysadmins
Learned something new?
Read more Software Engineering Lessons from Production
I write articles with real insight into the career and skills of a modern software engineer. "Raw and honest from the heart!" as one reader described them. Fueled by lessons learned over 20 years of building production code for side-projects, small businesses, and hyper growth startups. Both successful and not.
Subscribe below 👇
Software Engineering Lessons from Production
Join Swizec's Newsletter and get insightful emails 💌 on mindsets, tactics, and technical skills for your career. Real lessons from building production software. No bullshit.
"Man, love your simple writing! Yours is the only newsletter I open and only blog that I give a fuck to read & scroll till the end. And wow always take away lessons with me. Inspiring! And very relatable. 👌"
Have a burning question that you think I can answer? Hit me up on twitter and I'll do my best.
Who am I and who do I help? I'm Swizec Teller and I turn coders into engineers with "Raw and honest from the heart!" writing. No bullshit. Real insights into the career and skills of a modern software engineer.
Want to become a true senior engineer? Take ownership, have autonomy, and be a force multiplier on your team. The Senior Engineer Mindset ebook can help 👉 swizec.com/senior-mindset. These are the shifts in mindset that unlocked my career.
Curious about Serverless and the modern backend? Check out Serverless Handbook, for frontend engineers 👉 ServerlessHandbook.dev
Want to Stop copy pasting D3 examples and create data visualizations of your own? Learn how to build scalable dataviz React components your whole team can understand with React for Data Visualization
Want to get my best emails on JavaScript, React, Serverless, Fullstack Web, or Indie Hacking? Check out swizec.com/collections
Did someone amazing share this letter with you? Wonderful! You can sign up for my weekly letters for software engineers on their path to greatness, here: swizec.com/blog
Want to brush up on your modern JavaScript syntax? Check out my interactive cheatsheet: es6cheatsheet.com
By the way, just in case no one has told you it yet today: I love and appreciate you for who you are ❤️