OpenBSD 7.5 via QEMU on Hetzner physical machine (no phys. access / KVM console)
hackmd.gfuzz.de
hackmd.gfuzz.de
It made me sad to see that Hetzner had discontinued the FreeBSD rescue system. But it seems to be correct: https://community.hetzner.com/tutorials/freebsd-openzfs-via-...
How much did it really cost them to have the mfsbsd image available?
I have some notes on doing that, including notes on my setup for disk encryption with FreeBSD on Hetzner:
https://gist.github.com/ctsrc/9a72bc9a0229496aab5e4d3745af0b...
This is of course easier (although the KVM software is a heap of proprietary arse with a web interface or ancient Java blob), but if you are truly paranoid you will have to trust the Hetzner staff and their software stack not to bring something undesired along with your provided image.
But it is not the initial setup I am really worried about. It is those fan meet fecies moments. Being able to respond to a situation instantly. Mfsbsd was a godsend.
Trying to fix problems on one OSis from a different OS is a much harder issue. Especially under pressure.
I would much rather have seen they added OpenBSD to their PXE environment. Just the vanilla stuff - no fancy optimizations.
I've actually built a small tool that has the UX of regular SSH but under the hood reboots into rescue, configures the keys and opens an SSH session. Once you close it, it reboots back into regular mode.
I've wrapped that tool again to then build a tool that takes just an ignition config and automatically images a hetzner server with fedora coreos using that config.
You could easily build your own tool that reboots into rescue, installs a VM, mounts all the necessary devices, boots the OS image, and exposes the serial console of that VM to you.
It took me a while to learn to love Hetzner's solution, but I prefer it over having to use shitty proprietary KVMs.
I got annoyed with the openssh bugs this summer and figured I should have some hosts I can mostly not worry about.
In general, I think I want OpenBSD to be the Internet-facing hosts as much as possible, so looking into proxy options for TLS+QUIC.
I've used relayd in front of a ruby on rails app that spawns 4 sockets, but I don't see why you would do it for httpd.
Note that httpd is based on relayd and likely still shares a lot of the same code.
Ended up there for more or less the same reason. Shame there isn't more hosted BSD options around.
https://github.com/nix-community/nixos-anywhere
I tried it on a Hetzner VPS and was honestly pretty surprised that it even worked. What makes it even cooler is that you can continue to rebuild the machine’s config remotely even after initialization (thanks to NixOS).
Of course, if what you already have works and/or you aren’t using NixOS in the first place, this probably is not the right tool for you.
Any issues or recommendations considering the Proxmox route? You do port forwarding or multiple ipv4?
Thanks for putting this idea in my head!
I also have an instance of PFSense running and any VMs that don't need a full IP address to themselves can just be port forwarded through the firewall.
I know you can do this with iptables but I am too lazy to learn how it works.
The only tweak -- auto-detection of swap space, as it is derived from RAM available and you cannot give all 100% RAM to qemu. So you need to adjust for it.
https://www.dim13.org/Install-OpenBSD-on-remote-host-without...
Trick with qemu works, but is veeeeery slow if you need a lot of disk access (ZFS zmirror scrub, or ZFS `send | receive` pipe or something like this).
I’ve also got OpenBSD 7.5 running on a Hetzner server, but it runs “natively”. By which I mean it’s still a VM from Hetzner, but I don’t have my own nested QEMU layer or anything.
1. https://cdn.openbsd.org/pub/OpenBSD/7.5/amd64/bsd.rd
2. installboot also needs /usr/mdec/biosboot and /usr/mdec/boot from base75.tgz.
wget -O - https://cdn.openbsd.org/pub/OpenBSD/X.Y/arm64/minirootXY.img |
dd if=/dev/stdin of=/dev/sdaHowever, if you ever have issues and need a rescue image, you'd need to figure out how to do something like the OP, and do it while learning how to do it for the first time rather than having had a practice run when you first installed it.
Pardon my potential ignorance, but as someone that usually does the right thing security-wise, is there really much of an advantage to signify(1) and Sha256 if we are pulling the key and hash over the same HTTPS connection as what we are about to verify? It is not like with sysupgrade(8) where we have a trusted key already on disk.
If you're just relying on HTTPS alone it means you're essentially trusting the certificate store that Hetzner put there for you.