Linux serverlinux web serverNETWORK ADMINISTRATIONS

FINALLY trying out NixOS – Best Server Linux Distro??

Yes! You can use NixOS as your homelab server distro! In this video, I try it out for the first time and learn along the way about firewall, package installation, and the configuration file.
Learn More: https://techhut.tv/nixos-best-server-os-setup/

👏SUPPORT TECHHUT
BUY ME A COFFEE: https://buymeacoffee.com/techhut
HOSTINGER: https://bit.ly/techhut-hostinger
YOUTUBE MEMBER: https://bit.ly/members-techhut

🏆FOLOW TECHHUT
TWITTER: https://bit.ly/twitter-techhut
MASTODON: https://bit.ly/mastodon-techhut
INSTAGRAM: https://bit.ly/personal-insta

📷MY GEAR (PAID LINKS)
ASUS ROG M16: https://amzn.to/3t8Xgpo
DeepCool MATREXX 40: https://amzn.to/3q3K8Qn
AMD 3700x: https://amzn.to/31AKX9N
ASRock B550M: https://amzn.to/3qeymTv
G.Skill Trident Z Neo: https://amzn.to/3JRbeSF
Radeon RX 580: https://amzn.to/3n7Ax9g
Cannon M50: https://amzn.to/3xLfhuA

00:00 – What is NixOS?
01:30 – Download and FLASH!
02:53 – Installing NixOS
04:17 – /etc/nixos/configuration.nix
05:33 – Enable OpenSSH and Rebuild
06:13 – Network Connection and IP
07:20 – SSH Keys
07:38 – Read the DOCS!
08:05 – Easy Docker Setup
10:13 – NixOS Firewall (Portainer Setup)
12:29 – Cockpit is AWESOME
14:34 – Are you using NixOS?

source

by TechHut

linux web server

31 thoughts on “FINALLY trying out NixOS – Best Server Linux Distro??

  • Thx for the tip gonna spinn up a vm with it today and test it out.

  • ive been dual booting nixos for about a month now and its awesome

  • I could be wrong, but it may have been because you tried to go to port 9433 instead of 9443; I think typically Docker does handle the firewall configuration, but I've also never run it rootless.

    Would be love to know if that was the issue or if the firewall config was needed too.

  • The other errors (actually warnings despite the red) you mentioned are just a couple of renamed options in the latest (24.95) version of NixOS. I’m guessing your config was started with a 23.11 default config, rather than a 24.05 default config. It’s just a case of finding and replacing the one instance of `services.xserver.layout` to `services.xserver.xkb.layout`, and the same for `variant`.

    Awesome to see more people getting into NixOS, thanks for the video!

  • I have seen a lot of nixos videos and never felt like using it. But this video, with the simplicity of Brandon, made me feel like I should use it as well.

  • Thx for this particular topic! I am using NixOS as a desktop and as a server too. You can use the combo NixOS/Incus for homelab! Very nice as you can stay in the NixOS realm for both Incus server and linux(NixOS) containers (LXC) 🙂

  • I was thinking the same thing of making a NixOS Jellyfin media server instead of Ubuntu one 🙂 Thanks!

  • I like usually like the documentation in the config file, but this seems like a bit much. I would rather start fresh with a blank file where I can overwrite the defaults instead of tweaking the giant file full of defaults.
    I know it doesn't technically make a difference, but it just feels better that way.

  • NixOS is amazing about recreation and whatnot – until you need to perform system administration because something within nix breaks

    Like imagine you cant even use the nix rollback

  • nix-shell alone makes it worth it to use Nix. I switched about a year ago and have not looked back.

  • Nixos is my daily driver with OpenSuse kalpa

  • You can also put containers (systemd containers, who knew 🙂) into the nix config as well. So you could deploy a whole system + containers with a single text file. Pretty cool

  • I glad you try NixOS too. I'm use it too on my lovely laptop and I love it with it. Don't forget for trying setup Flakes too, Bro. You will get much advantages from it. Good job 👍🏻

  • They just need to throw an equivalent for `archinstall` on it.

  • I've just started playing with NixOS and it's very different but I can see why people like it. Once I finish wrapping my head around it I could easily see it becoming part of my homelab setup.

  • 1. Set's up NixOS (awesome!)
    2. Throws away most NixOS benefits by using docker

    Also docker bypasses the firewall on any Linux system by applying iptables rules automatically.

  • Might replace debian12 with this, just wondering will a deskpi pro work script install ok, anyone know?

  • NixOS is what got me to stop jumping distros, with home-manager and flakes it's pretty much perfect for my desktop and server needs. As for your setup I'd recommend at least getting flakes set up, and dropping docker in favor of running your services the Nix way, your docker containers are unmanaged state, when you copy over your config to a new machine they won't be carried over.

  • I think NixOS is actually a server oriented distro. I used it as my desktop daily driver for a year and it took a lot of shenanigans to make it work. Turns out immutability and lack of dynamic libraries may not be something you need nor want. Came back to Pop OS and I'm happy with it.

    For the server though, NixOS is the wet dream of any sysadmin.

  • I noticed you used the port 9433 instead of port 9443 at time 10:40, Wondering if you did need to open the ports in the firewall section.

  • It's not all sun shine and rainbows. Wait till you have no internet and have to fix something or use a binary. That being said, the good far outweighs the bad so that's why it's still my daily driver.

  • You don't need to add Cockpit as a package, setting it up as service takes care of that for you 🙂

  • The reason we use the method of adding users to groups declaratively separately is so if you want to remove docker you can just edit it in one area. This way it will remove docker and you from the group instead of removing the line for docker and going all the way to your user section. Best to use the user settings at the top as a base you can put on any machine and only add to the groups if the services are there.

Comments are closed.