ogmini - Exploration of DFIR

Having fun while learning about and pivoting into the world of DFIR.

15 January 2025

Investigating Lab Automation - MSLab

by ogmini

I am in the process of planning and building my next hypervisor for use in my homelab. Looking for infrastructure as code or scripting options to easily spin up test labs is proving to be an interesting journey. There are the standard options of Terraform, Ansible, Vagrant, and the various cloud vendor specific implementations.

My current server is running Hyper-V and I’m likely to stay with it though I am also looking at using Proxmox as an alternative. In this post, we’ll go with the assumption of sticking with Hyper-V and investigate the Proxmox option in the future.

MSLab

I came across this Microsoft project on Github called MSLab https://github.com/microsoft/MSLab that looked like a nice option. It is intended to easily spin up test labs with a Domain Controller and clients. Creating an environment that you can test out upgrades or other changes. The project is essentially a collection of Powershell scripts.

At the moment, it mainly supports Microsoft parent images and only has “experimental” support for Linux parent images. It lists Debian 11 and RHEL 8.

What is nice is that MSLab can be run on pretty much any Windows OS that has Hyper-V. So you could run this on Windows 10/11 Pro or any of the Server variants with Hyper-V. I’m hoping to get a moment to spin this up on a test machine just to see how it runs before I get all the parts for the new server.

https://github.com/microsoft/MSLab?tab=readme-ov-file#use-cases - some general use cases as described in their README.

tags: tools - homelab