Blog Posts

Hosting OpenStreetMap on NixOS

September 26, 2023 by Jacek Galowicz

This journey towards running OpenStreetMap on NixOS began as a part of a solution for a client, but the ease and speed of NixOS made it an eye-opening experience. Let’s explore the practicality of OpenStreetMap on NixOS in this article, where I show how to describe a running configuration as a NixOS module.

Read more

Running nginx with multiple PHP versions on NixOS with and without Containers

September 4, 2023 by Jacek Galowicz

Two weeks ago I gave a class about server security at the linuxhotel. Although the class had nothing to do with NixOS, one of the participants asked me during a coffee break, how hard it would be to configure a web server with NixOS that provides multiple versions of PHP at the same time. Let’s have a look at how this is simple in NixOS. As an extra, let’s run the whole setup in a declarative systemd-nspawn container to fulfill last week’s promise!

Read more

Running NixOS from any Linux Distro in systemd-nspawn Containers

August 29, 2023 by Jacek Galowicz

When showing Nix or NixOS to newcomers, the first instinct is often to run the NixOS Docker image on Docker or Podman. This week we’re having a look at how to do the same with systemd’s systemd-nspawn facility via the machinectl command. This has huge benefits to both trying out NixOS and also professionally using it like a sidecar VM, as we shall see. If you’re using Ubuntu, Debian, Fedora, Rocky Linux, or similar, jump right in!

Read more

Remote Deployments with nixos-rebuild

August 10, 2023 by Jacek Galowicz

In last week’s article, we got to know nixos-rebuild a bit closer: We’ve seen how it can be used to switch to a new system configuration, or only test the new system configuration in a VM. This week, we shift up a gear and look at nixos-rebuild’s remote building and deploy capabilities.

Read more

Magic Deployments with nixos-rebuild

July 31, 2023 by Jacek Galowicz

One of the things you learn after installing NixOS for the first time is that all these tasks are basically the same from a tooling perspective: Adding/removing a package, massively changing the system configuration, or simply updating it. After changing the configuration and/or the inputs, you run nixos-rebuild and the system is deployed. If the configuration turns out to be bad - it can simply be rolled back! But how does this tool work and what other cool features does it have?

Read more

Newer Older