Tag - Ubuntu


Remote shutdown script for Linux/Windows

I’ve been writing a lot of bash scripts recently to make my life a little easier. I have 15 VMs in my homelab running on ESXi. I had to shutdown my server recently to do some maintenance (i.e. adding more ram as it was running out and I didn’t particularly want to do SSD caching for the host) and had to manually shutdown all of my VMs. I started doing this and realised that there must be a better way of doing this and it turns out there is.

Read More


Ubuntu startup script that controls an Arduino chip

I’ve got an Arduino that controls a lamp in my bedroom that goes off at 5:30 (I don’t get up at that ungodly hour by choice) weekdays and different times on weekends. This helps me get up and out of bed a bit more naturally. I won’t go into how it works (maybe a topic for another blog post) but I thought I’d share how to create a startup script for Ubuntu.

Read More


UFW all traffic through tunnel

To use UFW to direct all traffic though a certain interface (like an OpenVPN tunnel) you can use UFW. It comes pre-installed with Ubuntu but not enabled. The only issue with it is that you have to disable the firewall, connect to your tunnel then re-enable the firewall to make it work. I find that's acceptable.

Read More