Scott's Recipes Logo

Useful NGINX Command Lines and Config Stuff

Last Updated On: 2025-09-01 04:31:52 -0400

Having just did a massive rewrite of two of my blogs:

Sidebar: About This Type of Blog Post

I write this style of blog post a lot:

  1. I do something.
  2. I know that I’m going to have to do it again in the future.
  3. I write down the important bits of what I did.

I don’t claim that this is magical or significant knowledge here – what it is though is a distillation of several hours of work and dozens of google searches / opened and discarded browser tabs.

If you’re a practicing software engineer / side project hacker / person who builds stuff online, I’d encourage you to follow this type of practice:

Generate Your Config Online

I used the Digital Ocean config generator here. My exact config that it generated can be found here.

The errors I had (and at least part of them were mine):

Useful Command Lines

Here are the commands I used:

To get my lets encrypt working:

certbot

To restart nginx:

systemctl restart  nginx

To check my nginx config:

nginx -t

To symlink both sites:

ln -s /etc/nginx/sites-available/recipes.fuzzyblog.io.conf /etc/nginx/sites-enabled/
ln -s /etc/nginx/sites-available/new.fuzzyblog.io.conf /etc/nginx/sites-enabled/

To check nginx’s status:

systemctl status nginx.service

Thank You

Thanks to: