Monday, October 12, 2026

I Now Have A Functional (and Private) Git Server

I've been struggling with wrapping my head around Git the past 4-5 years.  It sounds silly, yeah, but I'm old school.  

I started my first position in the IT Security field in 2003.  There was no such thing as Infrastructure as Code (IaC).  The first time I remember hearing of IaC was in 2017.  Note that I didn't enter the sub-field of security engineering in a dedicated fashion up until 2017.  In my prior positions, I didn't need to be familiar with such information.

I didn't even start being involved with Docker up until 5 years ago.  I was initially pushed to it by work - my supervisor wanted each team to be familiar with it, so I tool an ACloudGuru course.  I didn't use it at work after finishing the course (and the course didn't cover Git), either, but I got some ideas on how to use it at home (in the home lab).  

I wanted to use Docker containers to replace a lot of my old computers within my lab, but actually ended up using it to install Wordpress on a Docker instance, hoping to replace my Wodrpress website with a dockerized instance.  I intially set up Wordpress on my LAN as a container stack.  When I saw how easy it was to set up, and after I tested and ran it maybe 6 months on my LAN, I replaced the server instance with a docker instance on the hosted server (Linode).  It was super easy and I think it runs more efficiently.  I just restored a good known backup onto the Dockerized Wordpress.

At this point, I've tested several containerized Wordpress setups, seeking greater efficiency, so there were tons of compose files that I wasn't tracking because I kept avoiding Git (and couldn't even understand it).

Only tonight, after speaking with a coworker about it, after gaining understanding of it when researching it (and Terraform usage), and after asking Gemini AI questions, I was able to give it a shot.

For Git, I'm using a Gitea as a container.  I used Gemini to ask questions on how to set up a private Git that I could keep track of all my code (across 3 different Docker host systems, on the LAN and from a public server, as well).

For each Docker host, I've created a repo to track that host's Docker code.  It took a long while to understand that I had to push the IaC files to the Gitea server.  I initially didn't even have an idea of how to map out the repos.  I was a total mess.

Now that I've the repos set up, I do not want to have to set it all up again, but if I had to, it would probably go a lot quicker in setting things up.  I'd love to be able to back up the repos to my NAS (if that's even possible).

The next steps will be to pull repo files, edit them, and merge them, or to use it to create new repos (with new files, instead of just pushing large batches of old code to a GIT UI).