Transforming an Old Laptop into a Home Lab: AKA, How I’m trying to DeGoogle myself

Intro to the labor!

Another project! This one has actually been in the works for quite some time now, but I’ve just now made what I think is an MVP for this.

I’ve been working on an ongoing project to repurpose an old ThinkPad X1 Carbon into a self-hosted Homelab. This came about because, as an avid Google Workspace user, I found out that Google was offloading their workspace efforts to Squarespace. It hit me that my data should be under my control. This first homelab is the first step in my Self Hosting journey.

This also became a great chance to self host several applications I use on the regular, such as VSCode and RStudio, along with integrating a locally contained cloud based photo album for the family.

This endeavor was both a challenge and a learning opportunity. Here’s how an aging laptop was transformed into a functional and productive homelab!

Let’s begin!


The Hardware Foundation

Laptop Specs and Setup

  • Model: ThinkPad X1 Carbon (2nd Gen)
  • Operating System: Ubuntu 22.04.3 LTS
  • Processor: Intel i7-4600U
  • Memory: 8 GB
  • Other Specs: 1600x900 display, Intel Haswell-ULT GPU

I purchased this ThinkPad X1 Carbon (2nd Gen) for $40, specifically with the intention of transforming it into a minimal yet functional home lab. It’s… seen better days. Now it’s in retirement sitting on the bookshelf in my office.

The X1 Carbon, despite its years, proved to be a reliable workhorse for this project. Ubuntu 22.04.3 LTS was a natural choice for the operating system, offering stability, a robust community for support, and a chance to utilize one of my Ubuntu Pro tokens.

On we go!

The Home Lab Blueprint

Objectives and Tools

  • Primary Goal: To create a versatile homelab environment.
  • Key Components:
    • RStudio and Visual Studio Code instances for work, aka fantasy baseball calculations on the fly.
    • A network storage solution acting as a cloud drive.
    • PhotoPrism for managing family photos.
  • Technology Stack: The entire setup is orchestrated using Docker containers, ensuring isolation and ease of management.
  • File Management with CasaOS: I incorporated CasaOS as the file manager and web interface for the homelab. It provided an intuitive and streamlined way to access and manage the various services and allowed for a quick interface when working with on board containerization of CasaOS friendly apps.

Networking and Access

Local and Remote Access Configuration

  • Network Setup: The laptop was assigned a static IP in my home network for consistency and initial testing.
  • Domain Management: I purchased a domain through Cloudflare earlier this year in order to test the water with Cloudspace’s ease of use and security functions.
  • Remote Access: I utilized Cloudflare’s Zero Trust capabilities to securely tunnel local ports to the web. This approach not only enhances security but also simplifies external access without complex network configurations.
  • Dashboard: A dashboard site was quickly created utilizing a Jekyll Website, which ended up being hosted on Netlify, as Cloudflare was having some issues processing the build.

So, the site is up:

Yeah, we’re still a “little” Google heavy here, but self hosting options are being explored. Right now I’m looking at Seafile, but more to come on that in the future.

But how is the lockdown through Cloudflare working…

Yessssss…

Additionally, each site is also password protected via setup in the yml and I’ve restricted traffic to the United States, so I can access this homelab whenever I travel.


The Central Hub: Dashboard and Hosting

GitHub and Netlify Integration

  • Initially, I’m hosting the main dashboard site on GitHub, displayed through Netlify’s CDS.
  • Future Plans: I aim to transition to hosting this dashboard locally and tunnel it through Cloudflare for more streamlined access and control. I’ll be attempting this through Nginx Proxy Manager, which I was trying to use initially until I found out about Cloudflare tunneling.

Reflections and Learning Points

Challenges and Triumphs

  • Software Configuration: Docker was instrumental in simplifying the deployment of various services. The learning curve here was steep but rewarding.
  • Networking Nuances: Setting up Cloudflare tunneling was a new deal for me. It required a careful understanding of DNS settings and secure web exposure.

Closing Thoughts

So what did we learn???

  • This project was not just about leveraging old hardware but also about learning and applying new technologies and concepts in a practical, home-based environment. The journey from conception to realization of this home lab has been both professionally enriching and personally gratifying.

Future Directions

Evolving Into a High-Availability Cluster

I want both of these sites, jeffmosdef.com and this site as well, to be hosted locally. Because of that, some things need to happen.

  • In the next phase of this home lab project, I aim to step into clustering in order to create a High Availability (HA) environment. This will be a significant learning opportunity for me, as I plan to set up a small cluster that ensures reliable home networking and robust web hosting capabilities. The focus will be on achieving a system that is not only more resilient to individual hardware failures but also offers improved service uptime and redundancy.

  • To complement the HA cluster, I plan to integrate additional dashboards, like Grafana, for real-time monitoring and analytics. These tools will be pivotal in capturing and visualizing metrics from the HA cluster, providing insights into its performance, resource utilization, and overall health. Implementing such monitoring solutions will not only aid in proactive management but also enhance my understanding of the system’s dynamics. It’s a crucial step towards a more informed and controlled home lab environment.

  • By implementing an HA setup, I anticipate enhancing the overall stability and reliability of the network and hosted services. This progression aligns perfectly with my objective to continuously evolve the home lab, creating a balance between advanced functionality, heightened security, practical ease of use, and of course… fun.

This project, starting with what was sold as a “scraptop” ThinkPad X1 Carbon, is a fantastic example of how older technology can be revitalized and employed in innovative ways. It’s an exciting step forward in my self-hosting and personal technological growth path. Thanks for the read!