Creating a Github Hosted Blog

Currently taking a cybersecurity bootcamp through work as a side hustle.  Part of what I'm doing in the class is documenting some things for myself and for others in the cohort that they might want to also do for the inevitable job hunt.  Today's effort is spinning up a professional blog.  

First off, there has already been a discussion about whether putting out this kind of personal website is something to do as a cybersecurity person.  I don't agree with that line of thinking.  We aren't a bunch of characters in Tinker Tailor Soldier Spy type movie.  We can humanize ourselves as well as use things like this to provide structure and a canvas to demonstrate the things we have learned.  I mean, fuck, are we supposed to start blasting Lose Yourself before a job interview and tell ourselves we got one shot, one opportunity?  

Keep the blog technical and keep it professional is about as far as I'll go with telling people how to approach creating content.  Highlight what you've learned, how you've grown, and how you approach solving and learning shit.

Next point is that in a perfect world, people would show off their awesome Terraform skills to spin up a secure techstack with a mature ci/cd pipeline as well as a dev and prod environments hosted in multiple datacenters.  Knock yourself out if you want to over-engineer things in that direction.  But for this purpose we don't need that level effort.  Minimum viable candidate not a fait accompli is the goal.  Once it's up and running then you can look at doing some real system design work.  That being said here is the techstack that I'll advocate for:

  • Github - We'll use this to host the repository for the site itself, as well as use it's built in Github Pages infrastructure to generate/host a website from the code in our repository.
  • Domain Registrar - I've used Google Domains due to inertia more than anything else.  It bounces around on who's the cheapest or has what extras that are worth paying for.  
  • Editor - I like Publii since I can edit raw Markdown or use it's WYSIWYG mode.  People also swear by Visual Studio Code with a couple of plugins.  

Setting Up A Repo

If you haven't already gotten yourself a Github account please go get one.  I'll wait while you go do it....  Good, now that's out of the way you'll next have to create a publicly viewable repository.  What that means is that the source code for your future website will be viewable by everyone but only you can make edits or allow others edits to happen.  I explicitly spell that out because there are people who are new to Github and that distinction isn't always burned in.  

When you create the repo you have to be very precise with the name of it.  USERNAME.github.io.  So in my case this is my repo.  https://github.com/Chad-Ballay/Chad-Ballay.github.io.  Here is the official github guide for doing this. https://docs.github.com/en/pages/quickstart

I want to be very clear here.  Following the official document will get you the beginning of a blog that you'll have to edit using Markdown that is based off of the Jekyll framework.  This is a good thing and is perfectly fine.  I use a different framework so that is why my repo will have a different structure than yours.  Full stop at this point if you wish.  Otherwise, coming up next is using Publii

Using Publii And Why It Is Great.

I like the Publii editor.  It helps me with the content creation headache.  Sometimes I want to crank out my Markdown code so that I can very precisely render something.  Most times I want to type into a glorified word processor and just point and click my way into something reasonable looking.  It handles that for me and it's an Open Source project so I feel good about using it and backing it with a monthly contribution.  (You can use it for free, I just mention that I support it to highlight I'm such a fan that I'm putting my money where my mouth is.)  It runs on Windows, Mac, and Linux so unless you are really running some esoteric shit, you can run it as well.  https://getpublii.com/

Once it's installed you need to point it at your public repo.  There is a chunk of initial setup work that you'll have to do but once it's done, you'll just click a button and deploy your posts to your blog.  In fact here is the guide that walks you through doing this.  https://getpublii.com/docs/host-static-website-github-pages.html

At the end of all this headache you'll be able to do something like this for writing content.

TOBECONTINUED.  It's saturday night so this'll have to be finished tomorrow.